summaryrefslogtreecommitdiffstats
path: root/clang/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* [AST] Associate the getter/setter methods to a property of a objc class ↵Argyrios Kyrtzidis2012-02-281-4/+8
| | | | | | | | | | extension. [libclang] Index the getter/setter methods of a property of a objc class extension. Fixes rdar://10907597 llvm-svn: 151633
* Some more Solaris fixes. Now successfully building libc++ on Solaris with ↵David Chisnall2012-02-283-13/+21
| | | | | | clang (and linking clang against it). llvm-svn: 151632
* Remove stray semi-colons.Daniel Dunbar2012-02-281-2/+2
| | | | llvm-svn: 151631
* [analyzer] Leaks should be uniqued by the allocation point in theAnna Zaks2012-02-281-5/+12
| | | | | | closest function context (Keychain API). llvm-svn: 151613
* [analyzer] Fix Malloc False Positive (PR 12100)Anna Zaks2012-02-282-8/+29
| | | | | | | | When allocated buffer is passed to CF/NS..NoCopy functions, the ownership is transfered unless the deallocator argument is set to 'kCFAllocatorNull'. llvm-svn: 151608
* Implement IRGen for the retain-autorelease in the lambda ↵Eli Friedman2012-02-283-2/+27
| | | | | | conversion-to-block-pointer outside of ARC. Testcases coming up soon. llvm-svn: 151603
* [analyzer] teach analyzer about ObjC literals, thus trimming out a false ↵Ted Kremenek2012-02-283-0/+23
| | | | | | | | | | positive with the malloc() checker involving comparing literal addresses to nil. Fixes <rdar://problem/10579586> llvm-svn: 151602
* Re-enable the Darwin ARM integrated assembler.Jim Grosbach2012-02-271-3/+2
| | | | | | All known nightly-test failures are fixed. llvm-svn: 151595
* [analyzer] Leaks should be uniqued by the allocation point in theAnna Zaks2012-02-271-6/+13
| | | | | | | | | closest function context. This prevents us from uniqueing all leaks from the same allocation helper. radar://10932226 llvm-svn: 151592
* [analyzer] Don't generate an explicit ExplodedNode for StringLiterals; have ↵Ted Kremenek2012-02-272-9/+7
| | | | | | the SVal lazily generated from Environment::getSVal(). llvm-svn: 151589
* Hack in a loud error for PR12086. Better than a silent miscompile.Sebastian Redl2012-02-271-1/+12
| | | | llvm-svn: 151586
* When evaluating integer expressions include a check for sub-expressionsArgyrios Kyrtzidis2012-02-271-1/+21
| | | | | | | | depth and error if we exceed a max value, to make sure we avoid a stack overflow. This is a hacky temporary fix. rdar://10913206. llvm-svn: 151585
* After numerous requests, have Objective-C 'method declared here' notes ↵Ted Kremenek2012-02-272-8/+16
| | | | | | mention the actual method. This looks better within an IDE, where text isn't always regurgitated in the presentation of a warning. Fixes radar 10914035. llvm-svn: 151579
* Implement a FIXME for conversion sequence distinction. Should fix PR12092.Sebastian Redl2012-02-271-2/+10
| | | | llvm-svn: 151577
* [analyzer] Add -analyzer-stats, which hooks up LLVM stats tracking.Anna Zaks2012-02-272-0/+4
| | | | | | As in http://llvm.org/docs/ProgrammersManual.html#Statistic llvm-svn: 151570
* Fix a couple bugs in the way we handle array indexes in array bounds ↵Eli Friedman2012-02-271-4/+4
| | | | | | checking. Specifically, make sure we don't ignore explicit casts in indexes, and make sure we use unsigned extension/comparisons on indexes. Fixes <rdar://problem/10916006>. llvm-svn: 151569
* Move "clang/Analysis/Support/SaveAndRestore.h" to "llvm/ADT/SaveAndRestore.h"Argyrios Kyrtzidis2012-02-277-7/+7
| | | | | | | | to make it more widely available. Depends on llvm commit r151564 llvm-svn: 151566
* Convert initializer lists to temporaries in CreateBuiltinBinOp. Allows ↵Sebastian Redl2012-02-271-0/+19
| | | | | | assignment of init lists to built-in types and resolves PR12088. llvm-svn: 151551
* Add missing code for compound literals of complex type. ↵Eli Friedman2012-02-271-0/+4
| | | | | | <rdar://problem/10938628> llvm-svn: 151549
* Revert testing code I committed by mistake in r151464.Argyrios Kyrtzidis2012-02-271-4/+4
| | | | llvm-svn: 151548
* Serialize InitListExpr's initializesStdInitializerList bit, so it's not left ↵Benjamin Kramer2012-02-272-0/+2
| | | | | | | | uninitialized. Found by valgrind. llvm-svn: 151527
* ObjcInterfaceTypes are also complete types for the type cache.Eric Christopher2012-02-271-3/+3
| | | | | | Fixes rdar://10934887 llvm-svn: 151519
* Ensure that we delete default constructors in the right cases. Don't delete theRichard Smith2012-02-271-11/+9
| | | | | | | default constructor of a union if it has a const member with no user-provided default constructor. llvm-svn: 151516
* Fix decltype crash-on-invalid, if we don't find a matching ')' for an ill-formedRichard Smith2012-02-271-2/+2
| | | | | | decltype expression. llvm-svn: 151515
* Half of PR12088: parse braced-init-lists on the RHS of assignment operators.Richard Smith2012-02-261-3/+14
| | | | | | | | If the assignment operator is a scalar type, we continue to incorrectly reject the initializer, but semantic analysis (and codegen) is correct for overloaded operators. llvm-svn: 151508
* Reorder members to save padding.Benjamin Kramer2012-02-261-4/+4
| | | | | | | | There's more potential here, but these Exprs aren't used that often so I don't feel like doing heroic bit packing right now. -8 bytes on every class changed (x86_64). llvm-svn: 151501
* Move FullSourceLoc::dump into the .cpp file, the used attribute made us emit ↵Benjamin Kramer2012-02-261-0/+4
| | | | | | this into every TU that includes SourceLocation.h. llvm-svn: 151493
* Don't assert when trying to diagnose why a class with a constructor template isRichard Smith2012-02-261-9/+25
| | | | | | non-trivial. llvm-svn: 151486
* A follow-up to r151482 which added support for powerpc and powerpc64Chandler Carruth2012-02-261-0/+10
| | | | | | | | | | | | | | | | | Debian multiarch libraries, this should in theory add support for those platform's header search rules. I don't have a system to check this with, so review appreciated. I've added the corresponding tests referring to the debian multiarch tree. We are starting to have a relatively completely tested Linux platform for header search and library search, with several interesting peculiarities. We should point people at the debian_multiarch_tree when suggesting new tests. Folks with Debian systems that can check this for correctness, it would be much appreciated. The missing chunks I know of are testing bi-arch peudo-cross-compiling toolchains betwen 32-bit and 64-bit variants of platforms, and the MIPS and ARM Debian toolchains. llvm-svn: 151484
* Ensure that we delete destructors in the right cases. Specifically:Richard Smith2012-02-263-105/+100
| | | | | | | | | | | | | | - variant members with nontrivial destructors make the containing class's destructor deleted - check for a virtual destructor after checking for overridden methods in the base class(es) - check for an inaccessible operator delete for a class with a virtual destructor. Do not try to call an anonymous union field's destructor from the destructor of the containing class. llvm-svn: 151483
* Add support for PPC and PPC64 multiarch toolchains on Debain.Chandler Carruth2012-02-261-0/+9
| | | | | | | | | | | | | | | | | Patch from Michel Dänzer, sent our way via Jeremy Huddleston who added 64-bit support. I just added one other place where powerpc64-linux-gnu was missing (we only had powerpc64-unknown-linux-gnu). I've also added a tree to test out the debian multiarch stuff. I don't use debian regularly, so I'm not certain this is entirely accurate. If anyone wants to check it against a debian system and fix any inaccuracies, fire away. This way at least folks can see how this is *supposed* to be tested. It'd be particularly good to get the Debian MIPS toolchains tested in this way. llvm-svn: 151482
* Make sure we don't try to produce a definition of an implicitly-deleted functionRichard Smith2012-02-262-8/+15
| | | | llvm-svn: 151478
* Special members which are defaulted or deleted on their first declaration areRichard Smith2012-02-261-0/+53
| | | | | | | | | | | | | trivial if the implicit declaration would be. Don't forget to set the Trivial flag on the special member as well as on the class. It doesn't seem ideal that we have two separate mechanisms for storing this information, but this patch does not attempt to address that. This leaves us in an interesting position where the has_trivial_X trait for a class says 'yes' for a deleted but trivial X, but is_trivially_Xable says 'no'. This seems to be what the standard requires. llvm-svn: 151465
* Revert r151460 as it is not enough to address the issue.Argyrios Kyrtzidis2012-02-251-52/+38
| | | | | | | | | | | Original log: When evaluating integer expressions handle logical operators outside VisitBinaryOperator() to reduce stack pressure for source with huge number of logical operators. Fixes rdar://10913206. llvm-svn: 151464
* Richard Smith pointed out that there already is a proposal for init list ↵Sebastian Redl2012-02-251-8/+18
| | | | | | mangling. llvm-svn: 151462
* When evaluating integer expressions handle logical operators outsideArgyrios Kyrtzidis2012-02-251-34/+48
| | | | | | | | | VisitBinaryOperator() to reduce stack pressure for source with huge number of logical operators. Fixes rdar://10913206. llvm-svn: 151460
* Initializer lists are now supported.Sebastian Redl2012-02-251-1/+1
| | | | llvm-svn: 151458
* CodeGen support for global variables of type std::initializer_list<X>.Sebastian Redl2012-02-253-3/+121
| | | | | | | | | | | | | This emits a backing array with internal linkage and fills it with data, then has the initializer_list point at the array. Dynamic initialization and global destructors are correctly supported. What doesn't work is nested initializer_lists. I have no idea how to get them to work, either. However, these should be very rare, and so I'll just call it a known bug and declare generalized initializers DONE! llvm-svn: 151457
* Fix crashers on unexpected std::initializer_list layouts. Found by inspection.Sebastian Redl2012-02-251-0/+4
| | | | llvm-svn: 151456
* Better mangling for new-expressions. Also, although we can't mangle ↵Sebastian Redl2012-02-251-4/+15
| | | | | | arbitrary initializer lists yet (we will need this), turn the crash into a controlled error. llvm-svn: 151455
* Temporarily revert r151288:Chad Rosier2012-02-251-2/+3
| | | | | | ARM: enable the integrated assembler by default for Darwin. llvm-svn: 151454
* ArrayRef'ize various functions in the AST/Parser/Sema.Ahmed Charles2012-02-2510-202/+220
| | | | llvm-svn: 151447
* Accept __has_feature(__feature__) as a synonym for __has_feature(feature) (andRichard Smith2012-02-252-3/+15
| | | | | | likewise for __has_extension). Patch by Jonathan Sauer! llvm-svn: 151445
* Fix r151443 to only apply C++11's exception for non-static data member accessRichard Smith2012-02-251-5/+14
| | | | | | | in cases where we would otherwise disallow the access, and add a -Wc++98-compat diagnostic for this C++11 feature. llvm-svn: 151444
* PR11956: C++11's special exception for accessing non-static data members fromRichard Smith2012-02-251-15/+15
| | | | | | unevaluated operands applies within member functions, too. llvm-svn: 151443
* Fix assertion (too few Diag arguments) when diagnosing a deleted operator deleteRichard Smith2012-02-251-1/+2
| | | | llvm-svn: 151442
* Teach CXXRecordDecl::hasIrrelevantDestructor to check the base classes andRichard Smith2012-02-254-3/+42
| | | | | | | | | data members for deleted or user-provided destructors. Now it's computed in advance, serialize it, and in passing fix all the other record DefinitionData flags whose serialization was missing. llvm-svn: 151441
* Fix a regression from r151117: ADL requires that we attempt to complete anyRichard Smith2012-02-252-6/+13
| | | | | | | | associated classes, since it can find friend functions declared within them, but overload resolution does not otherwise require argument types to be complete. llvm-svn: 151434
* Prevent llvm.lifetime intrinsics from being emitted at -O0.Chad Rosier2012-02-251-1/+5
| | | | | | rdar://10921594 llvm-svn: 151430
* Work-in-progress for lambda conversion-to-block operator. Still need to ↵Eli Friedman2012-02-255-32/+96
| | | | | | implement the retain+autorelease outside of ARC, and there's a bug that causes the generated code to crash in ARC (which I think is unrelated to my code, although I'm not completely sure). llvm-svn: 151428
OpenPOWER on IntegriCloud