summaryrefslogtreecommitdiffstats
path: root/clang/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* Privatize class members.Benjamin Kramer2009-12-101-2/+2
| | | | llvm-svn: 91067
* Add support for finding composite type of twp objective-c pointersFariborz Jahanian2009-12-101-0/+5
| | | | | | in objective-c++ mode. llvm-svn: 91059
* Improve the diagnostic when a new declaration conflicts with a using shadowJohn McCall2009-12-103-16/+18
| | | | | | | | declaration. Rename note_using_decl to note_using, which is possibly less confusing. Add a test for non-class-scope using decl collisions and be sure to note the case we can't diagnose yet. llvm-svn: 91057
* Move composite type finding of two objective-c expressions Fariborz Jahanian2009-12-102-118/+140
| | | | | | into its own helper method. No change in functionality. llvm-svn: 91056
* Implement C++ DR437, which involves exception-specifications that nameDouglas Gregor2009-12-101-4/+13
| | | | | | a type currently being defined, from Nicola Gigante! llvm-svn: 91052
* Move initialization via initializer list over to InitializationSequences.Douglas Gregor2009-12-103-18/+154
| | | | llvm-svn: 91050
* Implement redeclaration checking and hiding semantics for using ↵John McCall2009-12-108-75/+423
| | | | | | | | | | | declarations. There are a couple of O(n^2) operations in this, some analogous to the usual O(n^2) redeclaration problem and some not. In particular, retroactively removing shadow declarations when they're hidden by later decls is pretty unfortunate. I'm not yet convinced it's worse than the alternative, though. llvm-svn: 91045
* Fix for PR5515: allow "merging" array bounds both forwards and backwards.Eli Friedman2009-12-101-4/+13
| | | | llvm-svn: 91044
* Mangle static variables inside Objective-C methods in Objective-C++. We ↵Anders Carlsson2009-12-101-3/+24
| | | | | | currently mangle them the same way as gcc does. llvm-svn: 91042
* Get rid of static variable.Eli Friedman2009-12-103-4/+5
| | | | llvm-svn: 91041
* If we enter parens, colons can become un-sacred, allowing us to emitChris Lattner2009-12-102-5/+12
| | | | | | a better diagnostic in the second example. llvm-svn: 91040
* fix a more evil case of : / :: confusion arising in ?:.Chris Lattner2009-12-101-0/+3
| | | | llvm-svn: 91039
* fix incorrect parsing of bitfields pointed out by Doug. I choseChris Lattner2009-12-102-4/+11
| | | | | | | to use ColonProtectionRAIIObject in the C codepath even though it won't matter for consistency. llvm-svn: 91037
* Actually store the pointer into the global variable, spotted by Eli.Anders Carlsson2009-12-101-2/+5
| | | | llvm-svn: 91036
* Setup cleanup on eh edge out of the construction of the cleanup objectMike Stump2009-12-101-12/+6
| | | | | | during throw to deallocate the exception object. WIP. llvm-svn: 91035
* minimal fix for PR5743Chris Lattner2009-12-101-2/+2
| | | | llvm-svn: 91032
* Handle emitting static variables that have reference type.Anders Carlsson2009-12-101-1/+4
| | | | llvm-svn: 91027
* Separate generating code for static variables and global variables.Anders Carlsson2009-12-101-33/+59
| | | | llvm-svn: 91026
* Second half of r91023, saving files is good.Chris Lattner2009-12-101-0/+1
| | | | llvm-svn: 91024
* move GreaterThanIsOperatorScope into RAIIObjectsForParser. Add some moreChris Lattner2009-12-101-3/+21
| | | | | | | TODOs for other classes that could be moved out of Parser.h. I don't plan to do these in the near term though. llvm-svn: 91023
* fix PR5740: a colon is sacred when parsing case statement expressions!Chris Lattner2009-12-102-1/+14
| | | | llvm-svn: 91016
* refactor the 'ColonIsSacred' argument to ParseOptionalCXXScopeSpecifierChris Lattner2009-12-104-11/+31
| | | | | | | to be a bool in Parser that is twiddled by the ColonProtectionRAIIObject class. No functionality change. llvm-svn: 91014
* Move more decl related functions to CGDeclCXX.cppAnders Carlsson2009-12-102-117/+117
| | | | llvm-svn: 91012
* rename ExtensionRAIIObject.h -> RAIIObjectsForParser.hChris Lattner2009-12-106-9/+10
| | | | llvm-svn: 91008
* Add CGDeclCXX.cpp and move EmitCXXGlobalVarDeclInit there.Anders Carlsson2009-12-103-45/+63
| | | | llvm-svn: 91006
* spread 'const' love to some variables. this considerably reduces the amount ↵Nuno Lopes2009-12-105-6/+6
| | | | | | of dirty data around. llvm-svn: 91002
* Fixup spacing.Mike Stump2009-12-101-41/+41
| | | | llvm-svn: 91001
* Fix spacing.Mike Stump2009-12-101-1/+1
| | | | llvm-svn: 91000
* Ensure we only generate one terminate handler.Mike Stump2009-12-103-2/+8
| | | | llvm-svn: 90998
* Remove obsolete FIXME and some dead fallback code.Mike Stump2009-12-091-6/+0
| | | | llvm-svn: 90997
* Add terminate handler to cleanups on exceptional edges.Mike Stump2009-12-091-3/+2
| | | | llvm-svn: 90996
* Code gen for ObjCIsaExpr AST used as lvalue.Fariborz Jahanian2009-12-094-15/+25
| | | | | | (fixes radar 7457534). llvm-svn: 90995
* Add terminate handler for copy constructors for thrown objects. WIP.Mike Stump2009-12-091-2/+16
| | | | llvm-svn: 90994
* Fix null dereference in OSAtomicChecker and special case SymbolicRegions. ↵Ted Kremenek2009-12-091-4/+13
| | | | | | We still aren't handling them correctly; I've added to failing test cases to test/Analysis/NSString-failed-cases.m that should pass and then be merged in to test/Analysis/NSString.m. llvm-svn: 90993
* Reimplement reference initialization (C++ [dcl.init.ref]) using theDouglas Gregor2009-12-0910-52/+1614
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | new notion of an "initialization sequence", which encapsulates the computation of the initialization sequence along with diagnostic information and the capability to turn the computed sequence into an expression. At present, I've only switched one CheckReferenceInit callers over to this new mechanism; more will follow. Aside from (hopefully) being much more true to the standard, the diagnostics provided by this reference-initialization code are a bit better than before. Some examples: p5-var.cpp:54:12: error: non-const lvalue reference to type 'struct Derived' cannot bind to a value of unrelated type 'struct Base' Derived &dr2 = b; // expected-error{{non-const lvalue reference to ... ^ ~ p5-var.cpp:55:9: error: binding of reference to type 'struct Base' to a value of type 'struct Base const' drops qualifiers Base &br3 = bc; // expected-error{{drops qualifiers}} ^ ~~ p5-var.cpp:57:15: error: ambiguous conversion from derived class 'struct Diamond' to base class 'struct Base': struct Diamond -> struct Derived -> struct Base struct Diamond -> struct Derived2 -> struct Base Base &br5 = diamond; // expected-error{{ambiguous conversion from ... ^~~~~~~ p5-var.cpp:59:9: error: non-const lvalue reference to type 'long' cannot bind to a value of unrelated type 'int' long &lr = i; // expected-error{{non-const lvalue reference to type ... ^ ~ p5-var.cpp:74:9: error: non-const lvalue reference to type 'struct Base' cannot bind to a temporary of type 'struct Base' Base &br1 = Base(); // expected-error{{non-const lvalue reference to ... ^ ~~~~~~ p5-var.cpp:102:9: error: non-const reference cannot bind to bit-field 'i' int & ir1 = (ib.i); // expected-error{{non-const reference cannot ... ^ ~~~~~~ p5-var.cpp:98:7: note: bit-field is declared here int i : 17; // expected-note{{bit-field is declared here}} ^ llvm-svn: 90992
* Break out code for reuse. WIP.Mike Stump2009-12-092-22/+41
| | | | llvm-svn: 90991
* Fixes a bogus error when declaring an extern "C" array.Fariborz Jahanian2009-12-092-5/+13
| | | | | | (fixes radar 7457109). llvm-svn: 90986
* Add throw support. WIP.Mike Stump2009-12-091-1/+1
| | | | llvm-svn: 90982
* Codegen. support for ObjCIsaExpr AST which until nowFariborz Jahanian2009-12-092-3/+22
| | | | | | was not needed (fixes radar 7453430). llvm-svn: 90981
* Add DeclContext::dump.Anders Carlsson2009-12-091-0/+11
| | | | llvm-svn: 90974
* Refactor OSAtomic evaluation logic into OSAtomicChecker.Zhongxing Xu2009-12-094-151/+191
| | | | llvm-svn: 90968
* Use a temporary destination set such that we can clear fake auto transitions.Zhongxing Xu2009-12-091-3/+24
| | | | | | | | Otherwise, even when real evaluation occurs, the previous fake auto transitions would still be in the destination set, causing fake state bifurcation. llvm-svn: 90967
* First pass at implementing C++ enum semantics: calculate (and store) anJohn McCall2009-12-096-26/+64
| | | | | | | | | | | | "integer promotion" type associated with an enum decl, and use this type to determine which type to promote to. This type obeys C++ [conv.prom]p2 and is therefore generally signed unless the range of the enumerators forces it to be unsigned. Kills off a lot of false positives from -Wsign-compare in C++, addressing rdar://7455616 llvm-svn: 90965
* OSAtomic simulation: use the original region as the location to load from,Zhongxing Xu2009-12-092-4/+7
| | | | | | | | instead of the ElementRegion obtained from casts. Test cast: the leak cannot occur bacause the true branch cannot be taken. llvm-svn: 90964
* Look through using declarations when searching for allocation overloads.Anders Carlsson2009-12-091-1/+2
| | | | llvm-svn: 90961
* remove dead code.Zhongxing Xu2009-12-091-41/+0
| | | | llvm-svn: 90953
* Insert instead of assign to the dest node set, since we use the dest node setZhongxing Xu2009-12-091-1/+1
| | | | | | repeatedly. llvm-svn: 90952
* Fix for PR5730: make sure to consistently callEli Friedman2009-12-091-11/+5
| | | | | | PerformObjectArgumentInitialization from BuildCXXMemberCallExpr. llvm-svn: 90950
* Whitespace fix.Eli Friedman2009-12-091-2/+1
| | | | llvm-svn: 90949
* In CXXRecordDecl::forallBases, add the base to the "queue", so we walk more ↵Anders Carlsson2009-12-091-2/+4
| | | | | | than one heirarchy of classes. John, please review. llvm-svn: 90948
OpenPOWER on IntegriCloud