summaryrefslogtreecommitdiffstats
path: root/clang/Sema
Commit message (Collapse)AuthorAgeFilesLines
...
* Patch for objc2's property ASTs, as well as pretty-priting the ASTs.Fariborz Jahanian2007-11-062-3/+59
| | | | llvm-svn: 43778
* improve decl merging logic to be more correct withChris Lattner2007-11-061-0/+5
| | | | | | functions. Patch contributed by Nuno Lopes, thanks! llvm-svn: 43757
* Add better validation for array types when merging decls. PatchChris Lattner2007-11-061-1/+41
| | | | | | contributed by Oliver Hunt, thanks! llvm-svn: 43750
* Sema::ActOnClassMessage()...if a class method isn't found, lookup an ↵Steve Naroff2007-11-051-0/+4
| | | | | | instance method. Since all classes are also instances, this is appropriate. llvm-svn: 43708
* Add a method prototype slot/getter to the ObjCMessageExpr AST.Steve Naroff2007-11-031-5/+7
| | | | llvm-svn: 43666
* Implement rewrite rules for ObjC string constants.Steve Naroff2007-11-032-3/+5
| | | | llvm-svn: 43665
* Fix ownership model of ParseAST to allow the dtor of Chris Lattner2007-11-031-7/+8
| | | | | | | ASTConsumer to process the AST before it is destroyed. This allows elimination of HandleObjcMetaDataEmission. llvm-svn: 43659
* AST for @try statement.Fariborz Jahanian2007-11-022-0/+17
| | | | llvm-svn: 43640
* AST for @finally statement.Fariborz Jahanian2007-11-022-0/+9
| | | | llvm-svn: 43629
* AST build for @catch clause (this is work in progress).Fariborz Jahanian2007-11-012-0/+15
| | | | llvm-svn: 43628
* Remaining work to collect objective-c's type qualifiers and use them to encodeFariborz Jahanian2007-11-011-0/+25
| | | | | | method types. llvm-svn: 43617
* Propagate bitfield info.Devang Patel2007-11-011-1/+1
| | | | llvm-svn: 43613
* 1) More additions for objective-c's qualifier type.Fariborz Jahanian2007-10-312-4/+9
| | | | | | 2) Fixed a test failure (which should have failed all along!). llvm-svn: 43589
* Fixed problem with rewriting stand-alone @implementation (with no matching ↵Fariborz Jahanian2007-10-312-5/+9
| | | | | | | | @interface). A new test case added. llvm-svn: 43568
* Implement a more sensible strategy for ObjC built-in types (addressing a ↵Steve Naroff2007-10-314-108/+68
| | | | | | | | | | | | long standing FIXME in Sema::GetObjcIdType()). This removes several gross hacks to work around the previous "lazy" behavior. Two notes: - MinimalActions still needs to be taught about the built-in types (This breaks one of the -noop test cases). I started this, then added a FIXME. - I didn't convert Sema::GetObjcProtoType() yet. llvm-svn: 43567
* After Anders check-in, we can now encode 'Class' type.Fariborz Jahanian2007-10-311-2/+2
| | | | llvm-svn: 43556
* Encode Class, SEL and Objective-C objects.Anders Carlsson2007-10-313-0/+33
| | | | llvm-svn: 43540
* Added new type and bitfield fields in some decl types in preparation for ↵Fariborz Jahanian2007-10-311-0/+4
| | | | | | | | objective-c's type qualifiers. Added initialization of Class/SEMA types. llvm-svn: 43534
* Stop pre-defining objc_msgSend/objc_getClass in the preprocessor. Instead, I ↵Steve Naroff2007-10-301-0/+2
| | | | | | generate these declaration on the fly when rewriting a message expression. llvm-svn: 43529
* Tightened IgnoreParen.Ted Kremenek2007-10-301-7/+2
| | | | llvm-svn: 43517
* minor tweaksChris Lattner2007-10-302-12/+13
| | | | llvm-svn: 43515
* Revisited my last patch to be able to do encoding of ivar types with 'id'.Fariborz Jahanian2007-10-301-9/+18
| | | | llvm-svn: 43507
* Added type encoding for 'id' type.Fariborz Jahanian2007-10-301-0/+8
| | | | llvm-svn: 43504
* - Add location info to category/protocol AST'sSteve Naroff2007-10-302-20/+26
| | | | | | - Rewrite categories. llvm-svn: 43501
* Remove a couple FIXME's for rewriting ObjC interfaces (which are now being ↵Steve Naroff2007-10-301-1/+1
| | | | | | rewritten properly). llvm-svn: 43494
* More support for rewriting ObjC intefaces. Still some edge cases to handle...Steve Naroff2007-10-302-12/+20
| | | | llvm-svn: 43493
* This commit contains lot's of small tweaks to how we pass around and store ↵Steve Naroff2007-10-292-17/+21
| | | | | | SourceLocation's for interfaces/protocols/categories/implementations. llvm-svn: 43475
* Added some comments.Ted Kremenek2007-10-291-1/+10
| | | | | | | Moved a dependent predicate in an if statement to be an assertion within the if statement body. llvm-svn: 43453
* For non-floating point types, added check for expressions of the formTed Kremenek2007-10-291-0/+7
| | | | | | | | | "x == x" and "x != x". We emit a warning for these since they always evaluate to a constant value and often indicate a logical error. Added test case for this check. llvm-svn: 43450
* For floating point equality check, we now ignore parentheses. e.g.:Ted Kremenek2007-10-291-2/+16
| | | | | | (x) == x is the treated the same as x == x. llvm-svn: 43448
* For checking for floating point comparison using == or !=, we now suppressTed Kremenek2007-10-291-3/+13
| | | | | | | | errors for cases such as "x == x". Added test case to test this feature. llvm-svn: 43447
* when checking for type equality, ignore typedefs.Chris Lattner2007-10-291-2/+2
| | | | llvm-svn: 43441
* casting to void is ok for structs (C99 6.5.4p2), this fixesChris Lattner2007-10-291-8/+9
| | | | | | one bogus error on PR1750. llvm-svn: 43436
* Implement *skeletal* support for representing GNU inline asm stmts in the AST,Chris Lattner2007-10-292-0/+7
| | | | | | | resolving a crash on a .i file in PR1750. We now generate 49 errors on the .i file in that bug. llvm-svn: 43433
* Start rewriting ObjC interfaces. As a start, we comment out all the methods. ↵Steve Naroff2007-10-262-4/+7
| | | | | | This involved refining how the parser/AST passes/manages SourceLocations for ObjcMethodDecl's. llvm-svn: 43404
* This patch allows synthesis generation of ivar offset for legacy objective-c ↵Fariborz Jahanian2007-10-261-2/+9
| | | | | | | | @implementation decl without an @interface decl. llvm-svn: 43403
* Patch to synthesize computation of Ivar offset in rewritten c file.Fariborz Jahanian2007-10-261-0/+2
| | | | | | Thanks to Steve N. to point out using of offsetof for this. llvm-svn: 43391
* Fix a crash on test/Sema/invalid-decl.c Chris Lattner2007-10-191-1/+7
| | | | llvm-svn: 43188
* Fix the previous (short lived:-) FIXME.Steve Naroff2007-10-181-2/+3
| | | | | | | | | | | | | | | | | I didn't realize that GCC considers this a hard error (I thought it was built-in). Since it's not, we should simply emit an error. [dylan:~/llvm/tools/clang] admin% cc -c trivial.m trivial.m:6: error: cannot find interface declaration for 'NSConstantString' [administrators-powerbook59:~/llvm/tools/clang] admin% ../../Debug/bin/clang trivial.m trivial.m:6:16: error: cannot find interface declaration for 'NSConstantString' NSString *s = @"123"; ^ 1 diagnostic generated. llvm-svn: 43157
* Check for Nullness of value built in GetObjcProtoType.Fariborz Jahanian2007-10-181-0/+2
| | | | llvm-svn: 43155
* Add a FIXME to an assert.Steve Naroff2007-10-182-2/+3
| | | | | | Change a dyn_cast_or_null back to cast (which is more efficient). llvm-svn: 43152
* Patch to rewrite ivar tables metadata for classes defined.Fariborz Jahanian2007-10-181-2/+3
| | | | llvm-svn: 43151
* Tweak a recent fix to UsualArithmeticConversions (made by Chris - r43113). ↵Steve Naroff2007-10-181-4/+6
| | | | | | The benefit of this tweak is it guarantees the entire routine operates on unqualified types (which I believe is a bit clearer). llvm-svn: 43142
* Fix a bug in Sema::CheckConditionalOperands(). When mixing pointers and null ↵Steve Naroff2007-10-181-13/+16
| | | | | | | | | | pointer constants, we need to promote the null pointer constant (which is an integer) to the pointer type. Test case is self explanatory. This surfaced yesterday, when compiling test/Sema/cocoa.m on Leopard. Since this has nothing to do with ObjC, it's kind of bizarre this hasn't shown up before. I imagine Cocoa.h on Leopard may have changed recently? Thanks to Ted for localizing the bug and giving me a useful AST dump... llvm-svn: 43114
* UsualArithmeticConversions is crashing with an assertChris Lattner2007-10-181-2/+2
| | | | | | | | | when comparing "float" and "const float". This "fixes" the issue, but may not be the right fix. Steve, please review. Testcase here: test/Sema/usual-float.c llvm-svn: 43113
* Fix the following bug...Steve Naroff2007-10-181-1/+1
| | | | | | | | | | | | | | | | | unsigned char asso_values[] = { 34 }; int legal2() { return asso_values[0]; } The code that creates the new constant array type was operating on the original type. As a result, the constant type being generated was "unsigned char [1][]" (which is wrong). The fix is to operate on the element type - in this case, the correct type is "unsigned char [1]" I added this case to array-init.c, which clearly didn't catch this bogosity... llvm-svn: 43112
* Implementation of AST for @protocol expression.Fariborz Jahanian2007-10-173-0/+42
| | | | llvm-svn: 43075
* Generate code for static variables that don't have initializers. Also, ↵Anders Carlsson2007-10-172-6/+18
| | | | | | report an error if a static initializer is not constant. llvm-svn: 43058
* Fix location processing of @selector: the range should include the @ sign.Fariborz Jahanian2007-10-162-0/+2
| | | | llvm-svn: 43051
* Add Sema::CheckMessageArgumentTypes()...Steve Naroff2007-10-162-5/+79
| | | | llvm-svn: 43050
OpenPOWER on IntegriCloud