Devang Patel
1216b05d3d
During interface layout, don't forget super class.
...
llvm-svn: 52033
2008-06-06 01:50:12 +00:00
Ted Kremenek
3ad519441f
Fix crash when running with multiple source files. This can be improved.
...
llvm-svn: 52032
2008-06-06 01:47:30 +00:00
Steve Naroff
d32ae8edf2
Oops...remove weird printf:-)
...
llvm-svn: 52025
2008-06-05 22:58:33 +00:00
Steve Naroff
946166f4e9
Second half of "fix" for <rdar://problem/5986085> clang on xcode: error: redefinition of 'XCElementToggler' as different kind of symbol
...
llvm-svn: 52024
2008-06-05 22:57:10 +00:00
Ted Kremenek
dfa8c8aef5
Ignore a few more linker arguments.
...
llvm-svn: 52023
2008-06-05 22:46:24 +00:00
Steve Naroff
a44099f022
super fix submitted by David Chisnall.
...
llvm-svn: 52014
2008-06-05 18:14:25 +00:00
Steve Naroff
31e1d41338
Fixed a recent test regression from last night (r51976).
...
llvm-svn: 52006
2008-06-05 15:03:27 +00:00
Steve Naroff
25449a5221
Fix <rdar://problem/5986833> clang on xcode: incompatible type returning 'void', expected 'int'.
...
- Changed Sema::ObjCActOnStartOfMethodDef() to more accurately type "self" in factory methods.
- Changed Sema::ActOnInstanceMessage() to use the new type to restrict the lookup.
llvm-svn: 52005
2008-06-05 14:49:39 +00:00
Steve Naroff
f9c65246dd
Fix <rdar://problem/5987482> clang on xcode: null dereference in Sema::ActOnMemberReferenceExpr.
...
In addition to fixing the crasher, this commit fixes further improves property lookup (by searching protocols of qualified interfaces..."NSObject <prot>").
llvm-svn: 52001
2008-06-05 13:55:23 +00:00
Sanjiv Gupta
158143ad54
Emit debug information for global and static variables when -g is specified.
...
llvm-svn: 51993
2008-06-05 08:59:10 +00:00
Steve Naroff
d1c3d1130b
Fix trivial crasher and downgrade an error to warning (to match GCC).
...
llvm-svn: 51976
2008-06-05 04:33:44 +00:00
Steve Naroff
cfdf6166fc
Support "<p>" as a short-hand for "id<p>". Here's a comment from GCC (the only documentation I could find on it).
...
/* Make "<SomeProtocol>" equivalent to "id <SomeProtocol>" - nisse@lysator.liu.se . */
This commit adds the parser magic. The type associated with <p> is still incorrect. Will discuss with Chris.
llvm-svn: 51972
2008-06-05 00:02:44 +00:00
Steve Naroff
d5bf26fa26
Fix crash identified by <rdar://problem/5986085>.
...
llvm-svn: 51969
2008-06-04 23:08:38 +00:00
Devang Patel
dbb7263fd9
Add ObjCInterface layout support.
...
Reuse RecordLayout.
llvm-svn: 51968
2008-06-04 21:54:36 +00:00
Steve Naroff
524fbe8687
Update a test and add a FIXME.
...
llvm-svn: 51967
2008-06-04 21:38:52 +00:00
Devang Patel
21979193bb
Refactoring.
...
Move field layout code in a ASTRecordLayout member fn.
llvm-svn: 51966
2008-06-04 21:22:16 +00:00
Ted Kremenek
6da61be501
ccc-analyzer now properly eats the -install_name, -exported_symbols_list, -current_version, -compatibility_version, and -sectorder command line arguments.
...
llvm-svn: 51965
2008-06-04 20:49:03 +00:00
Ted Kremenek
46267c839d
Added fixmes.
...
llvm-svn: 51964
2008-06-04 20:48:08 +00:00
Steve Naroff
d9c2607014
Parser::ParseObjCSynchronizedStmt() needs to Enter/Exit a decl scope.
...
llvm-svn: 51963
2008-06-04 20:36:13 +00:00
Eli Friedman
3e1852fa7e
Make sure the types are consistent for a void conditional. No visible
...
difference, but it's better to be consistent.
llvm-svn: 51961
2008-06-04 19:47:51 +00:00
Eli Friedman
2425cd8158
For setting attributes, don't assume there are ParamVarDecls available,
...
because trying to access non-existent ParamVarDecls can crash.
Testcase from the original source for PR2414.
llvm-svn: 51960
2008-06-04 19:41:28 +00:00
Nuno Lopes
7bd6e58ddc
fix crash when codegening 'cond ? lhs : call-to-void-func()'
...
llvm-svn: 51958
2008-06-04 19:15:45 +00:00
Nuno Lopes
28bcfec325
fix type of ?: operator. If one of the operator is void, the type should be void as well.
...
Please confirm this is safe
llvm-svn: 51957
2008-06-04 19:14:12 +00:00
Fariborz Jahanian
6e59392e4b
Fix a gcc compatibility issue which allows more protocol-qualified id on RHS to be
...
assigned to less protocol qualified object on LHS.
llvm-svn: 51956
2008-06-04 19:00:03 +00:00
Eli Friedman
8547e1d129
Don't assume that the type of a FunctionDecl is a FunctionType; that
...
assumption isn't accurate in the presence of typedefs.
llvm-svn: 51951
2008-06-04 17:58:41 +00:00
Eli Friedman
67b827900e
Make the width and alignment for long double consistent with the
...
hardcoded data layout in getTargetDescription. Hopefully fixes a test
failure.
Of course, this should be fixed properly, but that's a bigger fix.
llvm-svn: 51948
2008-06-04 17:01:45 +00:00
Eli Friedman
c0b54901f4
clang fix to parallel LLVM r51928
...
(http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20080602/063306.html ).
llvm-svn: 51944
2008-06-04 16:13:19 +00:00
Ted Kremenek
b147ad1051
Moved LangOptions from TranslationUnit to ASTContext. This induced a variety of cleanups in some ASTConsumers.
...
llvm-svn: 51943
2008-06-04 15:55:15 +00:00
Ted Kremenek
1cb246ef20
Update Xcode project.
...
llvm-svn: 51941
2008-06-04 15:38:06 +00:00
Steve Naroff
c68e382ba9
ASTContext::typesAreCompatible(): id is compatible with all qualified id types.
...
llvm-svn: 51939
2008-06-04 15:07:33 +00:00
Steve Naroff
f4308aac53
Sema::ActOnClassMessage() needs to look through it's local implementation for private class methods.
...
llvm-svn: 51938
2008-06-04 14:43:54 +00:00
Argyrios Kyrtzidis
6301884dc0
Move Decl and DeclContext implementations into a new DeclBase.cpp file.
...
llvm-svn: 51936
2008-06-04 13:04:04 +00:00
Steve Naroff
5ccccf0326
Make sure we look through categories when searching for a classes property.
...
Fixes <rdar://problem/5984338> clang on xcode: property implementation must have its declaration in interface 'PBXOpenQuicklyModule'
llvm-svn: 51925
2008-06-04 04:46:04 +00:00
Steve Naroff
cff2688180
Give the "isa" slot a name!
...
llvm-svn: 51924
2008-06-04 03:03:48 +00:00
Steve Naroff
a2981a2c7b
Add a few more built-in functions.
...
llvm-svn: 51921
2008-06-03 22:16:48 +00:00
Steve Naroff
b115be707d
Put back my temporary hack until Eli addresses this in a more complete fashion.
...
llvm-svn: 51920
2008-06-03 22:06:04 +00:00
Steve Naroff
13c360cec4
Implement another property related FIXME:
...
Fix <rdar://problem/5967199> clang on xcode: error: member reference is not to a structure or union
llvm-svn: 51919
2008-06-03 21:56:14 +00:00
Eli Friedman
149614bfe7
Re-fix r51907 in a way which doesn't affect valid code. This essentially
...
moves the check for the invalid construct to a point where it doesn't
affect other uses of isIntegerConstantExpr, and we can warn properly
when the extension is used. This makes it a bit more complicated, but
it's a lot cleaner.
Steve, please tell me if this check is sufficient to handle the
relevant system header. I know it's enough to handle the testcase, but
I don't know what exactly the original looks like.
llvm-svn: 51918
2008-06-03 21:01:11 +00:00
Steve Naroff
ec62418fc5
Fixup recent "super" regression.
...
llvm-svn: 51913
2008-06-03 18:21:00 +00:00
Steve Naroff
5832c03509
Add a builtin. Fixes <rdar://problem/5982037> clang on xcode: error: incompatible operand types ('int' and 'char *').
...
llvm-svn: 51908
2008-06-03 17:37:43 +00:00
Steve Naroff
aaf5108d26
Change Expr::isIntegerConstantExpr() to allow for pointer types (for GCC compatibility). Note FIXME.
...
Fix <rdar://problem/5977870> clang on xcode: error: arrays with static storage duration must have constant integer length
llvm-svn: 51907
2008-06-03 17:15:29 +00:00
Steve Naroff
b788d9bd27
Allow implicit pointer/int conversions on ObjCQualifiedIdTypes in Sema::CheckCompareOperands() and Sema::CheckAssignmentConstraints().
...
Fixes <rdar://problem/5980804> clang on xcode: error: incompatible type sending 'id<XDUMLType>', expected 'NSCellType'.
llvm-svn: 51902
2008-06-03 14:04:54 +00:00
Steve Naroff
0b225dac9b
Finish up r51900.
...
llvm-svn: 51901
2008-06-03 13:21:30 +00:00
Steve Naroff
1ba306cde5
Allow for a GCC cast extension.
...
Fixes part of <rdar://problem/5980829> clang on xcode: used type 'NSRange' where arithmetic or pointer type is required.
llvm-svn: 51900
2008-06-03 12:56:35 +00:00
Chris Lattner
f4fee9e1e5
make rewrite macros insert a space when commenting out macros where the token didn't
...
lead with a space.
llvm-svn: 51896
2008-06-03 06:10:17 +00:00
Steve Naroff
b877e2c3ca
Fix parser bug/FIXME with @catch .
...
<rdar://problem/5980846> clang on xcode: error: declarator requires an identifier (for @catch )
llvm-svn: 51895
2008-06-03 05:36:54 +00:00
Steve Naroff
ebf4cb4841
Fix <rdar://problem/5979875> clang on xcode: error: use of undeclared identifier 'super'
...
llvm-svn: 51888
2008-06-02 23:03:37 +00:00
Ted Kremenek
88bfb62ffe
Use the correct 'ccc-analyzer' when the build command is a direct invocation of gcc.
...
llvm-svn: 51883
2008-06-02 21:52:47 +00:00
Chris Lattner
fd2fe8270e
handle the full assignment-expression grammar when using an
...
objc message send in an initializer expression.
llvm-svn: 51882
2008-06-02 21:31:07 +00:00
Steve Naroff
f611964230
Fix <rdar://problem/5976164> clang ObjC rewriter: for ... in enumeration inserts undeclared function (objc_enumerationMutation should be in preamble)
...
llvm-svn: 51880
2008-06-02 20:23:21 +00:00