Fariborz Jahanian
57251782d0
Code gen for aggregate-valued properties and a test case.
...
llvm-svn: 60122
2008-11-26 22:36:09 +00:00
Fariborz Jahanian
e7167c28f6
Removed a FIXME. Added a test case for anonymous category.
...
llvm-svn: 60115
2008-11-26 20:33:54 +00:00
Fariborz Jahanian
f8ef9f3dc9
Set default property attributes on each property.
...
Implemented anonymous category (also know as continuation class)
used to override main class's property attribute. This is work in
propgress.
llvm-svn: 60114
2008-11-26 20:01:34 +00:00
Anders Carlsson
f7a9a92359
Convert incomplete array types before emitting debug info for them, fixes PR3134.
...
llvm-svn: 60109
2008-11-26 17:40:42 +00:00
Nuno Lopes
8c6fbc04ee
add missing RUN lines
...
llvm-svn: 60107
2008-11-26 15:50:12 +00:00
Douglas Gregor
08d96d5182
Fix a minor typo in the handling of the conditional operator for Objective-C interface pointers
...
llvm-svn: 60096
2008-11-26 06:43:45 +00:00
Anders Carlsson
32ef8ceaa1
Handle returning complex types that get coerced. Fixes PR3131
...
llvm-svn: 60058
2008-11-25 22:21:48 +00:00
Fariborz Jahanian
9a207ee4dc
Patch to allow over-riding of readonly property to
...
a writable property in one of its category.
llvm-svn: 60035
2008-11-25 17:56:43 +00:00
Douglas Gregor
3ff3cf5f21
Test another error message, make sure to verify C++ new and delete tests
...
llvm-svn: 60007
2008-11-25 04:08:05 +00:00
Douglas Gregor
2afd0be069
Simple parsing of exception specifications, with no semantic analysis yet
...
llvm-svn: 60005
2008-11-25 03:22:00 +00:00
Zhongxing Xu
f39268ae8c
Add documentation for test.
...
llvm-svn: 60002
2008-11-25 01:45:11 +00:00
Zhongxing Xu
2939a50b67
Add no-warning to test case.
...
llvm-svn: 59995
2008-11-24 23:45:56 +00:00
Fariborz Jahanian
8fc3741b76
Patch to remove bogus waring when a property declaration
...
is imported from a protocol into the implementation.
llvm-svn: 59988
2008-11-24 22:16:00 +00:00
Chris Lattner
1e5665e6be
Change a whole lot of diagnostics to take QualType's directly
...
instead of converting them to strings first. This also fixes a
bunch of minor inconsistencies in the diagnostics emitted by clang
and adds a bunch of FIXME's to DiagnosticKinds.def.
llvm-svn: 59948
2008-11-24 06:25:27 +00:00
Chris Lattner
f3d3faeca6
Rename NamedDecl::getName() to getNameAsString(). Replace a bunch of
...
uses of getName() with uses of getDeclName(). This upgrades a bunch of
diags to take DeclNames instead of std::strings.
This also tweaks a couple of diagnostics to be cleaner and changes
CheckInitializerTypes/PerformInitializationByConstructor to pass
around DeclarationNames instead of std::strings.
llvm-svn: 59947
2008-11-24 05:29:24 +00:00
Anders Carlsson
a7c5eb72a0
Reimplement Expr::isConstantExpr in terms of Expr::Evaluate. This fixes PR2832.
...
llvm-svn: 59946
2008-11-24 05:23:59 +00:00
Zhongxing Xu
f556cd6cb9
Strings are NULL terminated. So the region size should plus one.
...
llvm-svn: 59943
2008-11-24 05:16:01 +00:00
Anders Carlsson
87da2b5dce
Forgot the newline :)
...
llvm-svn: 59942
2008-11-24 05:13:45 +00:00
Anders Carlsson
3abcb58a35
Add test case for bug that's been fixed.
...
llvm-svn: 59941
2008-11-24 05:11:21 +00:00
Anders Carlsson
a42ee44aab
The address of a variable is only constant if the variable has global storage.
...
llvm-svn: 59939
2008-11-24 04:41:22 +00:00
Anders Carlsson
4c76e93507
Fix bug in the constant evaluator. Fixes PR3115.
...
llvm-svn: 59938
2008-11-24 04:21:33 +00:00
Chris Lattner
86d7d91366
Rename NamedDecl::getIdentifierName() to ::getNameAsCString() and make it
...
assert if the name is not an identifier. Update callers to do the right
thing and avoid this method in unsafe cases. This also fixes an objc
warning that was missing a space, and migrates a couple more to taking
IdentifierInfo and QualTypes instead of std::strings.
llvm-svn: 59936
2008-11-24 03:54:41 +00:00
Zhongxing Xu
bf900755d0
Add test case for out-of-bound memory access checking.
...
llvm-svn: 59931
2008-11-24 02:19:49 +00:00
Chris Lattner
4fc69799f5
Rewrite FindDiagnostics to be more strict about the formatting of the
...
expected-foo strings. Now the only allowed characters between
expected-error and {{ is whitespace.
llvm-svn: 59925
2008-11-24 01:28:17 +00:00
Chris Lattner
f3ab014308
clean up -verify mode output. If the expected-error string is
...
mangled, report it using the diagnostics machinery instead of printf.
llvm-svn: 59924
2008-11-23 23:38:26 +00:00
Chris Lattner
12f7c5a36a
convert some more warnings to NOTEs.
...
llvm-svn: 59923
2008-11-23 23:26:13 +00:00
Chris Lattner
d068503565
remove warn_previous_declaration
...
llvm-svn: 59922
2008-11-23 23:20:13 +00:00
Chris Lattner
03c4041cb5
make the 'to match this' diagnostic a note.
...
llvm-svn: 59921
2008-11-23 23:17:07 +00:00
Chris Lattner
0369c57ac6
Make all the 'redefinition' diagnostics more consistent, and make the
...
"previously defined here" diagnostics all notes.
llvm-svn: 59920
2008-11-23 23:12:31 +00:00
Chris Lattner
e6447ef989
make some objc redefinition warnings more consistent: call definitions
...
"definitions", not declarations. Point out the location of the
original definition.
llvm-svn: 59919
2008-11-23 22:46:27 +00:00
Chris Lattner
88dcd2a1ab
Tweak duplicate category diagnostic to work like the duplicate protocol diagnostic.
...
Also, point out where the previous decl was. This unxfails two tests.
llvm-svn: 59918
2008-11-23 22:38:38 +00:00
Chris Lattner
e3d20d9545
Convert IdentifierInfo's to be printed the same as DeclarationNames
...
with implicit quotes around them. This has a bunch of follow-on
effects and requires tweaking to a whole lot of code. This causes
a regression in two tests (xfailed) by causing it to emit things like:
Line 10: duplicate interface declaration for category 'MyClass1' ('Category1')
instead of:
Line 10: duplicate interface declaration for category 'MyClass1(Category1)'
I will fix this in a follow-up commit.
As part of this, I had to start switching stuff to use ->getDeclName() instead
of Decl::getName() for consistency. This is good, but I was planning to do this
as an independent patch. There will be several follow-on patches
to clean up some of the mess, but this patch is already too big.
llvm-svn: 59917
2008-11-23 21:45:46 +00:00
Chris Lattner
f7e69d5a77
add support for inserting a DeclarationName into a diagnostic directly
...
without calling getAsString(). This implicitly puts quotes around the
name, so diagnostics need to be tweaked to accommodate this.
llvm-svn: 59916
2008-11-23 20:28:15 +00:00
Zhongxing Xu
60d6cd1940
Improve test case.
...
llvm-svn: 59902
2008-11-23 05:50:21 +00:00
Sebastian Redl
632ab20e1e
Fix test cases broken by quote normalization in diagnostics.
...
llvm-svn: 59888
2008-11-22 22:39:41 +00:00
Fariborz Jahanian
9ac535162b
Implemented ir-gen for 'implicit' properties using the new AST nodes.
...
llvm-svn: 59886
2008-11-22 22:30:21 +00:00
Anders Carlsson
475f4bce36
Case values must be evaluated
...
llvm-svn: 59884
2008-11-22 21:50:49 +00:00
Anders Carlsson
59689ed764
Use Expr::Evaluate for case statements. Fixes PR2525
...
llvm-svn: 59881
2008-11-22 21:04:56 +00:00
Fariborz Jahanian
5118c418e6
Support for implicit property assignment. Error assigning to
...
'implicit' property with no 'setter'.
llvm-svn: 59878
2008-11-22 20:25:50 +00:00
Chris Lattner
8cd9b96ee1
add a silly testcase
...
llvm-svn: 59877
2008-11-22 19:57:03 +00:00
Fariborz Jahanian
bf65ce5372
And a test case for my last patch.
...
llvm-svn: 59875
2008-11-22 18:40:47 +00:00
Sebastian Redl
15b02d2e62
Implement a %plural modifier for complex plural forms in diagnostics. Use it in the overload diagnostics.
...
llvm-svn: 59871
2008-11-22 13:44:36 +00:00
Anders Carlsson
4d5f2e532c
Add test for PR2992.
...
llvm-svn: 59861
2008-11-22 06:42:54 +00:00
Fariborz Jahanian
e2caaaa13c
Fixed bugzilla bug# 3095 related to code gen. for @synchronized.
...
llvm-svn: 59838
2008-11-21 19:21:53 +00:00
Sebastian Redl
bd150f431e
Implementation of new and delete parsing and sema.
...
This version uses VLAs to represent arrays. I'll try an alternative way next, but I want this safe first.
llvm-svn: 59835
2008-11-21 19:14:01 +00:00
Chris Lattner
cedef8d111
merge some simple call diagnostics.
...
llvm-svn: 59831
2008-11-21 18:44:24 +00:00
Chris Lattner
40bb0c83d4
print a type in a diagnostic.
...
llvm-svn: 59829
2008-11-21 18:27:34 +00:00
Douglas Gregor
5d58c3a568
Allow redeclaration of typedefs in C++
...
llvm-svn: 59822
2008-11-21 16:29:06 +00:00
Douglas Gregor
b81897cda6
Fix overloading of non-static member functions that differ in their cv-qualifiers
...
llvm-svn: 59819
2008-11-21 15:36:28 +00:00
Douglas Gregor
9eb16eadfb
Enable some more operator overloading tests, and don't look into an identifier for functions that might not have one
...
llvm-svn: 59818
2008-11-21 15:30:19 +00:00