summaryrefslogtreecommitdiffstats
path: root/clang
Commit message (Collapse)AuthorAgeFilesLines
* [analyzer] fix inlining's handling of mapping actual to formal arguments and ↵Ted Kremenek2012-01-127-19/+76
| | | | | | limit the call stack depth. The analyzer can now accurately simulate factorial for limited depths. llvm-svn: 148036
* constexpr: initialization of a union from an empty initializer-list shouldRichard Smith2012-01-123-8/+49
| | | | | | | | | zero-initialize the first union member. Also fix a bug where initializing an array of types compatible with wchar_t from a wide string literal failed in C, and fortify the C++ tests in this area. This part can't be tested without a code change to enable array evaluation in C (where an existing test fails). llvm-svn: 148035
* scanf: parse the 'm' length modifier, and check that the right argumentsHans Wennborg2012-01-126-7/+63
| | | | | | are used with that and the 'a' length modifier. llvm-svn: 148029
* In Objective-C++, actually compute the base type of a member accessDouglas Gregor2012-01-123-18/+38
| | | | | | | | expression for an Objective-C object or pointer type, so that we don't attempt to treat the member name as a template. Fixes <rdar://problem/10672501>. llvm-svn: 148028
* scanf analysis: the 'a' length modifier is valid with a scanlistHans Wennborg2012-01-123-1/+4
| | | | | | | Before r148025 we (accidentally) didn't check whether a length modifier is appropriate for a scanlist, but now we do. llvm-svn: 148026
* scanf analysis: don't bail out after successful parse of scanlistHans Wennborg2012-01-122-1/+5
| | | | llvm-svn: 148025
* test/Driver/debug-options*.c: Tweak r147819 to split out another ↵NAKAMURA Takumi2012-01-122-7/+11
| | | | | | cc1as-sensitive test. gcc driver is invoked for assembling on cygming. llvm-svn: 148022
* Revert accidentally-committed file in r148020.Richard Smith2012-01-121-3/+3
| | | | llvm-svn: 148021
* Allow constant-folding of references which were formed in a manner not permittedRichard Smith2012-01-124-14/+18
| | | | | | in a constant expression, for compatibility with g++. llvm-svn: 148020
* Add IsImplicit field in ObjCMessageExpr that is true when the messageArgyrios Kyrtzidis2012-01-1210-84/+172
| | | | | | | | | | was constructed, e.g. for a property access. This allows the selector identifier locations machinery for ObjCMessageExpr to function correctly, in that there are not real locations to handle/report for such a message. llvm-svn: 148013
* [arcmt] The migrator tests for the buildbot in ↵Argyrios Kyrtzidis2012-01-1232-32/+32
| | | | | | | | http://lab.llvm.org:8011/builders/clang-native-mingw32-win7/ are messed up, XFAIL does not help. Waiting until DISABLE is supported.. llvm-svn: 148012
* [analyzer] Rename Store::Retrieve() -> getBinding().Anna Zaks2012-01-126-67/+74
| | | | | | + all the other Retrieve..() methods + a comment for ElementRegion. llvm-svn: 148011
* [analyzer] Add taint transfer by strcpy & others (part 1).Anna Zaks2012-01-122-96/+134
| | | | | | | | | | | | To simplify the process: Refactor taint generation checker to simplify passing the information on which arguments need to be tainted from pre to post visit. Todo: We need to factor out the code that sema is using to identify the string and memcpy functions and use it here and in the CString checker. llvm-svn: 148010
* Fix test case committed in r147986.Akira Hatanaka2012-01-121-3/+3
| | | | llvm-svn: 147993
* Formatting.Eric Christopher2012-01-121-1/+1
| | | | llvm-svn: 147989
* Formatting.Eric Christopher2012-01-121-1/+1
| | | | llvm-svn: 147988
* Take into account the pointer to an aggregate that is passed as a hiddenAkira Hatanaka2012-01-122-2/+18
| | | | | | argument when Offset is initialized. llvm-svn: 147986
* Call CodeGenTypes::ConvertType to get LLVM::Type*.Akira Hatanaka2012-01-121-25/+4
| | | | | | Remove function MipsABIInfo::GetFloatingPointTy. llvm-svn: 147985
* Fix some edge cases with C++ casts and placeholder expressions.Eli Friedman2012-01-122-12/+24
| | | | llvm-svn: 147984
* objective-c: fixes a regression in looking up namesFariborz Jahanian2012-01-122-2/+25
| | | | | | | in class extensions and categories by recent refactoring of objc class ASTs. // rdar://1066654 llvm-svn: 147982
* Appease -Wnon-virtual-dtorMatt Beaumont-Gay2012-01-111-0/+2
| | | | llvm-svn: 147977
* Extend test-case as requested by EliDouglas Gregor2012-01-111-0/+4
| | | | llvm-svn: 147974
* Improve the diagnostic when trying to redefine a typedef with aDouglas Gregor2012-01-113-2/+15
| | | | | | variably-modified type. llvm-svn: 147973
* Fix the caching in CorrectTypo so that other non-keyword identifiersKaelyn Uhrain2012-01-113-2/+11
| | | | | | | | | | | | | | are still added if the cached correction fails validation. Also fix a copy-and-paste error in a comment from my previous commit. Finally, add an example of the benefit the typo correction callback adds to TryNamespaceTypoCorrection--which happens to also tickle the above caching problem, as the only way a non-namespace Decl would be added to the possible corrections is if it was cached as the correction for a previous instance of the same typo where the typo was corrected to a non-namespace via a different code path. llvm-svn: 147968
* minor refactoring to improve compile-time performance.Fariborz Jahanian2012-01-111-2/+2
| | | | llvm-svn: 147963
* Add initial callback object support to Sema::CorrectTypo.Kaelyn Uhrain2012-01-115-105/+229
| | | | | | | | | Also includes two examples of the callback: a wrapper/replacement for the CorrectTypoContext enum, and a conversion of the two calls to CorrectTypo in SemaDeclCXX.cpp (one of which provides verifiable improvement to the typo correction, as demonstrated in the added test). llvm-svn: 147962
* objc-arc: evaluate 'readonly' property with no knownFariborz Jahanian2012-01-113-6/+100
| | | | | | | life-time to that of its backing 'ivar's lifetime. // rdar://10558871 llvm-svn: 147956
* constexpr: fix typo resulting in move constructors sometimes not beingRichard Smith2012-01-112-2/+7
| | | | | | implicitly marked constexpr when they should be. llvm-svn: 147955
* More tests for ARM FPU features.Evgeniy Stepanov2012-01-111-0/+12
| | | | | | Also remove the svn:eol-style property from the test file. llvm-svn: 147947
* Fix -mfpu parsing on ARM.Evgeniy Stepanov2012-01-113-2/+49
| | | | | | | | | - Support gcc-compatible vfpv3 name in addition to vfp3. - Support vfpv3-d16. - Disable neon feature for -mfpu=vfp* (yes, we were emitting Neon instructions for those!). llvm-svn: 147943
* clang/test/CodeGen/vla-4.c: Relax expression for -Asserts.NAKAMURA Takumi2012-01-111-1/+1
| | | | llvm-svn: 147934
* Fixed VLA code generation.Abramo Bagnara2012-01-112-14/+46
| | | | llvm-svn: 147933
* "This change adds alloca/valloc checks to UnixAPIChecker. It includes a ↵Ted Kremenek2012-01-112-48/+99
| | | | | | | | | | | | small refactoring for the common *alloc functions as well as a few tiny wibbles (adds a note to CWE/CERT advisory numbers in the bug output, and fixes a couple 80-column-wide violations.)" Patch by Austin Seipp! llvm-svn: 147931
* test/Driver/debug-options-as.c: Mark this as XFAIL:cygwin.NAKAMURA Takumi2012-01-111-2/+2
| | | | | | Also cygwin has not supported integrated-as yet. llvm-svn: 147929
* C11 allows typedefs to be redefined. Implement this in C11 mode, andDouglas Gregor2012-01-114-9/+21
| | | | | | | downgrade the default-error warning to an ExtWarn in C90/99. <rdar://problem/10668057> llvm-svn: 147925
* Revert changes to lib/Driver in r147917; I didn't mean to commit this.Eli Friedman2012-01-111-20/+19
| | | | llvm-svn: 147920
* Add elidable CXXConstructExpr as block-level expr. It converts an lvalue to ↵Zhongxing Xu2012-01-112-643/+658
| | | | | | a rvalue, which is a useful step during AST evaluation. llvm-svn: 147918
* Start refactoring code for capturing variables and 'this' so that it is ↵Eli Friedman2012-01-116-134/+164
| | | | | | shared between lambda expressions and block literals. llvm-svn: 147917
* Typo in test.John McCall2012-01-111-2/+2
| | | | llvm-svn: 147905
* Remove '#if 0' from ExprEngine::InlineCall(), and start fresh by wiring up ↵Ted Kremenek2012-01-115-116/+89
| | | | | | | | | | inlining for straight C calls. My hope is to reimplement this from first principles based on the simplifications of removing unneeded node builders and re-evaluating how C++ calls are handled in the CFG. The hope is to turn inlining "on-by-default" as soon as possible with a core set of things working well, and then expand over time. llvm-svn: 147904
* Do placeholder conversions on array bounds in both declarators andJohn McCall2012-01-114-4/+30
| | | | | | new-expressions. llvm-svn: 147900
* Remove switch/case statements and call GetFloatingPointTy() instead to get theAkira Hatanaka2012-01-101-13/+1
| | | | | | floating point type. llvm-svn: 147894
* Flatten float complex arguments. N32/64 requires float complex arguments beAkira Hatanaka2012-01-101-4/+28
| | | | | | passed in floating point registers. llvm-svn: 147892
* Remove space.Akira Hatanaka2012-01-101-2/+2
| | | | llvm-svn: 147889
* Add field IsIEEE in FloatingLiteral to distinguish between different 128-bitAkira Hatanaka2012-01-103-5/+23
| | | | | | floating point formats. llvm-svn: 147887
* When something goes wrong in type-checking a namespace definition, make the ↵Douglas Gregor2012-01-101-1/+5
| | | | | | namespace declaration invalid llvm-svn: 147882
* Add support for the androideabi environment to our triple support, andChandler Carruth2012-01-103-2/+15
| | | | | | | | | | for the arm-linux-androideabi triple in particular. Also use this to do a better job of selecting soft FP settings. Patch by Evgeniy Stepanov. llvm-svn: 147872
* objc-arc: fixes a crash when trying to find out retaining cycleFariborz Jahanian2012-01-102-4/+36
| | | | | | ownership of property sent to 'super'. // rdar://10640891 llvm-svn: 147868
* Remove a set, but unused variable. Found with GCC's warning.Chandler Carruth2012-01-101-4/+1
| | | | llvm-svn: 147864
* [analyzer] Testing infrastructure: Flush output after every printAnna Zaks2012-01-101-1/+10
| | | | | | statement. llvm-svn: 147862
OpenPOWER on IntegriCloud