summaryrefslogtreecommitdiffstats
path: root/clang/test
Commit message (Collapse)AuthorAgeFilesLines
* Convert SemaExprMember.cpp to pass a callback object to CorrectTypo,Kaelyn Uhrain2012-01-132-3/+7
| | | | | | | | | improving the typo correction results in certain situations. This is also the first typo correction callback conversion to affect an existing unit test. :) llvm-svn: 148140
* rename -ccc-host-triple into -targetSebastian Pop2012-01-1371-241/+239
| | | | llvm-svn: 148138
* Reinstate test case accidentally reverted by r148028Douglas Gregor2012-01-131-4/+14
| | | | llvm-svn: 148118
* Don't infer a submodule for a framework's private header, at least for now.Douglas Gregor2012-01-131-1/+1
| | | | llvm-svn: 148117
* PR11754: Reject non-static constexpr member functions in classes with virtualRichard Smith2012-01-131-0/+4
| | | | | | base classes. llvm-svn: 148094
* A base subobject type doesn't make sense for unions; don't try to compute ↵Eli Friedman2012-01-131-6/+3
| | | | | | it. Based on patch by Yin Ma. Fixes PR11751. llvm-svn: 148093
* constexpr is allowed on static member functions of non-literal classes. Per ↵Eli Friedman2012-01-131-0/+6
| | | | | | report on cfe-dev. llvm-svn: 148090
* A few minor improvements to error recovery trying to access member of a ↵Eli Friedman2012-01-131-0/+10
| | | | | | function. In particular, this restores the cool error recovery for the example from http://blog.llvm.org/2010/04/amazing-feats-of-clang-error-recovery.html , which regressed a few months back. llvm-svn: 148089
* Don't crash while trying to diagnose a function declared at block scope with anRichard Smith2012-01-131-0/+4
| | | | | | incomplete return type. llvm-svn: 148088
* [analyzer] Unwrap the pointers when ignoring the const cast.Anna Zaks2012-01-131-0/+3
| | | | | | radar://10686991 llvm-svn: 148081
* [analyzer] RegionStoreManager::getBinding() should not crash whenAnna Zaks2012-01-131-0/+4
| | | | | | looking up value at a CodeTextRegion even when the type is not provided. llvm-svn: 148079
* objc parsing. Fixes a crash when parsing array initializationFariborz Jahanian2012-01-131-0/+23
| | | | | | inside a class implementation with parse errors. // rdar://10633434 llvm-svn: 148074
* Improve 0-argument -Wvexing-parse diagnostic by adding notes with fix-its:Richard Smith2012-01-126-15/+109
| | | | | | | | | | | | | | | | | | | | | | | - If the declarator is at the start of a line, and the previous line contained another declarator and ended with a comma, then that comma was probably a typo for a semicolon: int n = 0, m = 1, l = 2, // k = 5; myImportantFunctionCall(); // oops! - If removing the parentheses would correctly initialize the object, then produce a note suggesting that fix. - Otherwise, if there is a simple initializer we can suggest which performs value-initialization, then provide a note suggesting a correction to that initializer. Sema::Declarator now tracks the location of the comma prior to the declarator in the declaration, if there is one, to facilitate providing the note. The code to determine an appropriate initializer from the -Wuninitialized warning has been factored out to allow use in both that and -Wvexing-parse. llvm-svn: 148072
* Recommit r148056 with fixes to deal with weirdness with bitfields in unions.Eli Friedman2012-01-121-0/+11
| | | | | | Original message: Make sure adding a field to a struct never reduces its size. PR11745. llvm-svn: 148070
* Revert r148056 while I investigate failures.Eli Friedman2012-01-121-11/+0
| | | | llvm-svn: 148068
* Make sure adding a field to a struct never reduces its size. PR11745.Eli Friedman2012-01-121-0/+11
| | | | llvm-svn: 148056
* Adjust set of default checkers.Ted Kremenek2012-01-121-1/+0
| | | | llvm-svn: 148055
* Convert SemaCXXScopeSpec.cpp to pass a callback object to CorrectTypo,Kaelyn Uhrain2012-01-121-0/+8
| | | | | | improvng the typo correction results in certain situations. llvm-svn: 148052
* objc: do not warn when converting to a const id qualfied by itsFariborz Jahanian2012-01-121-0/+21
| | | | | | list of protools. // rdar://10669694 llvm-svn: 148051
* Convert SemaInit.cpp to pass a callback object to CorrectTypo.Kaelyn Uhrain2012-01-121-0/+12
| | | | | | | And once again improve the typo correction results in certain situations just by moving the existing checks on the correction. llvm-svn: 148037
* [analyzer] fix inlining's handling of mapping actual to formal arguments and ↵Ted Kremenek2012-01-121-0/+30
| | | | | | 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-122-0/+26
| | | | | | | | | 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-122-3/+24
| | | | | | 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-121-6/+15
| | | | | | | | 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-122-1/+3
| | | | | | | 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-121-0/+4
| | | | 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
* Allow constant-folding of references which were formed in a manner not permittedRichard Smith2012-01-122-1/+9
| | | | | | in a constant expression, for compatibility with g++. llvm-svn: 148020
* [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] Add taint transfer by strcpy & others (part 1).Anna Zaks2012-01-121-7/+34
| | | | | | | | | | | | 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
* Take into account the pointer to an aggregate that is passed as a hiddenAkira Hatanaka2012-01-121-0/+12
| | | | | | argument when Offset is initialized. llvm-svn: 147986
* Fix some edge cases with C++ casts and placeholder expressions.Eli Friedman2012-01-121-0/+9
| | | | llvm-svn: 147984
* objective-c: fixes a regression in looking up namesFariborz Jahanian2012-01-121-0/+20
| | | | | | | in class extensions and categories by recent refactoring of objc class ASTs. // rdar://1066654 llvm-svn: 147982
* 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-111-1/+1
| | | | | | variably-modified type. llvm-svn: 147973
* Fix the caching in CorrectTypo so that other non-keyword identifiersKaelyn Uhrain2012-01-111-0/+7
| | | | | | | | | | | | | | 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
* Add initial callback object support to Sema::CorrectTypo.Kaelyn Uhrain2012-01-111-0/+11
| | | | | | | | | 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-112-0/+45
| | | | | | | 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-111-0/+5
| | | | | | 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-111-0/+36
| | | | | | | | | - 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-111-0/+24
| | | | llvm-svn: 147933
* "This change adds alloca/valloc checks to UnixAPIChecker. It includes a ↵Ted Kremenek2012-01-111-0/+38
| | | | | | | | | | | | 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-112-2/+16
| | | | | | | downgrade the default-error warning to an ExtWarn in C90/99. <rdar://problem/10668057> llvm-svn: 147925
* Add elidable CXXConstructExpr as block-level expr. It converts an lvalue to ↵Zhongxing Xu2012-01-111-641/+657
| | | | | | a rvalue, which is a useful step during AST evaluation. llvm-svn: 147918
* 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-111-1/+0
| | | | | | | | | | 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
OpenPOWER on IntegriCloud