summaryrefslogtreecommitdiffstats
path: root/clang/lib
Commit message (Collapse)AuthorAgeFilesLines
* After discussion with Doug and John, I am revertingFariborz Jahanian2010-10-223-27/+2
| | | | | | the patch. llvm-svn: 117159
* Change handling of inline asm 'p' constraint to match llvm-gcc.Dale Johannesen2010-10-221-0/+2
| | | | llvm-svn: 117149
* Substantially revise how clang computes the visibility of a declaration toJohn McCall2010-10-229-277/+382
| | | | | | | | more closely parallel the computation of linkage. This gets us to a state much closer to what gcc emits, modulo bugs, which will undoubtedly arise in abundance. llvm-svn: 117147
* Patch fixes miscompile with non-trivial copy constructors and Fariborz Jahanian2010-10-223-2/+27
| | | | | | statement expressions, //rdar: //8540501 llvm-svn: 117146
* Delay record type's debug info emission, in -flimit-debug-info mode, if ↵Devang Patel2010-10-221-1/+2
| | | | | | member expression's base is call expr. llvm-svn: 117127
* Revert unintentional check-in.Devang Patel2010-10-221-1/+1
| | | | llvm-svn: 117120
* Don't try to guess svn version when current path is a symlink.Oscar Fuentes2010-10-221-1/+3
| | | | | | See PR 8473. llvm-svn: 117110
* Tidy up MIPS_linkage name. Provide it only if it does not match regular ↵Devang Patel2010-10-221-5/+18
| | | | | | | | name, otherwise it confuses debugger. This is tested by local.C in llvmgcc testsuite. llvm-svn: 117107
* More class anonymization.Benjamin Kramer2010-10-224-7/+13
| | | | llvm-svn: 117106
* Move classes into anonymous namespaces.Benjamin Kramer2010-10-222-18/+21
| | | | llvm-svn: 117104
* When performing name lookup for a namespace definition, only look intoDouglas Gregor2010-10-221-9/+11
| | | | | | | the current context's redeclaration context, ignoring using directives. Fixes PR8430. llvm-svn: 117097
* Teach the C++ simple-type-specifier parser and tentative parses aboutDouglas Gregor2010-10-214-66/+118
| | | | | | protocol-qualified types such as id<Protocol>. llvm-svn: 117081
* Rename clang's TBAA tree root from "experimental" to "simple".Dan Gohman2010-10-211-1/+1
| | | | llvm-svn: 117046
* Tweak diagnostics for redeclaration of a @property in a class extension ↵Ted Kremenek2010-10-211-1/+10
| | | | | | | | | | where the redelcaration and original declaration have the 'readwrite' attribute. This is a common case, and we can issue a more lucid diagnostic. Fixes <rdar://problem/7629420>. llvm-svn: 117045
* Tidy up comment (remove extraneous text).Ted Kremenek2010-10-211-2/+1
| | | | llvm-svn: 117044
* Add some more comments.Dan Gohman2010-10-212-4/+20
| | | | llvm-svn: 117043
* Implement the integral promotion rules for the C++0x char16_t andDouglas Gregor2010-10-211-14/+31
| | | | | | | char32_t character types and enable built-in overloaded operator candidates for these types. Fixes PR8432. llvm-svn: 117038
* Diagnose the declaration of template template parameters thatDouglas Gregor2010-10-212-2/+7
| | | | | | | | themselves have no template parameters. This is actually a restriction due to the grammar of template template parameters, but we choose to diagnose it in Sema to provide better recovery. llvm-svn: 117032
* Always treat 'main' as an extern "C" function, so that we detectDouglas Gregor2010-10-212-1/+6
| | | | | | | | | redeclarations of main appropriately rather than allowing it to be overloaded. Also, disallowing declaring main as a template. Fixes GCC DejaGNU g++.old-deja/g++.other/main1.C. llvm-svn: 117029
* When checking whether a return statement returns a stack-localDouglas Gregor2010-10-211-4/+11
| | | | | | | variable, handle conditional operators involving a throw-expression. Fixes GCC DejaGNU's g++.dg/template/cond4.C. llvm-svn: 117027
* Revert r117005, WIN32 is not predefined after all.Francois Pichet2010-10-211-1/+0
| | | | llvm-svn: 117026
* Tweak the ObjCAtSyncChecker to assume that a mutex is non-nil after checking ↵Ted Kremenek2010-10-211-3/+5
| | | | | | | | | that it is nil. Otherwise we can get false paths where a second @synchronized using the mutex can have a bogus warning. Fixes <rdar://problem/8578650>. llvm-svn: 117016
* MSVC defines WIN32 as a predefined macro.Francois Pichet2010-10-211-0/+1
| | | | llvm-svn: 117005
* Targets: Fix MinGW and VisualStudio predefined macros.Michael J. Spencer2010-10-211-12/+56
| | | | llvm-svn: 117003
* Reorganize predefined macros for all Windows targets.Michael J. Spencer2010-10-215-55/+92
| | | | | | | | | | This adds an option to set the _MSC_VER macro without recompiling. This is very useful when testing compatibility with the Windows SDK and c++stdlib headers. -fmsc-version=<version> (defaults to VS2003 (1300)) llvm-svn: 116999
* Previously, the printf warnings would say your arguments type was 'int' when ↵Ted Kremenek2010-10-212-3/+20
| | | | | | | | | | it was really a 'char' or a 'short'. This fixes that and allows the hints to suggest 'h' modifiers for small ints. Patch by Justin Bogner! llvm-svn: 116996
* Remove unused variable.Ted Kremenek2010-10-211-1/+0
| | | | llvm-svn: 116995
* Fix Whitespace.Michael J. Spencer2010-10-215-132/+132
| | | | llvm-svn: 116990
* Revert "Cleanup and fix predefined macros for windows."Michael J. Spencer2010-10-211-72/+53
| | | | | | Didn't realize this was on my branch ;/. llvm-svn: 116989
* Cleanup and fix predefined macros for windows.Michael J. Spencer2010-10-211-53/+72
| | | | llvm-svn: 116988
* Pass TInfo to CXXDestructorDecl::Create(), just like we do for otherCraig Silverstein2010-10-215-10/+8
| | | | | | | | function decls. Reviewed by rjmccall and nlewycky. llvm-svn: 116979
* When implicit members are added to a C++ record, notify the serializer so ↵Argyrios Kyrtzidis2010-10-201-0/+7
| | | | | | | | that a chained PCH writes the definition again. Thanks to Doug for the hint! llvm-svn: 116975
* Modify the assumptions of an assert; the updated latest redeclaration can ↵Argyrios Kyrtzidis2010-10-201-6/+6
| | | | | | | | have the same location if it's a template specialization pointing at the template. llvm-svn: 116974
* Remove obsolete GRAuditor and GRSimpleAPICheck, which have been completely ↵Ted Kremenek2010-10-202-91/+2
| | | | | | subsumed by the Checker interface. llvm-svn: 116973
* Convert GRSimpleAPIChecks in BasicObjCFoundationChecks to be Checkers.Ted Kremenek2010-10-203-263/+185
| | | | llvm-svn: 116971
* Extend the preprocessing record and libclang with support forDouglas Gregor2010-10-205-33/+154
| | | | | | | | | inclusion directives, keeping track of every #include, #import, etc. in the translation unit. We keep track of the source location and kind of the inclusion, how the file name was spelled, and the underlying file to which the inclusion resolved. llvm-svn: 116952
* Fix chained PCH issue; make sure all visible decls that will be put into a ↵Argyrios Kyrtzidis2010-10-201-1/+18
| | | | | | UPDATE_VISIBLE block were recorded beforehand. llvm-svn: 116931
* Minor optimization; Try to iterator over redeclarations only when necessary.Argyrios Kyrtzidis2010-10-201-9/+8
| | | | llvm-svn: 116930
* Fixes a potential crash in rewriter when sending message Fariborz Jahanian2010-10-201-12/+17
| | | | | | to 'super'. llvm-svn: 116928
* GCC 4.4 warns that Receiver may be used uninitialized in this function.Duncan Sands2010-10-201-1/+1
| | | | | | | | | As far as I can see, gcc is right to think this! The following change will cause a nice segfault rather than undefined behaviour if this case occurs. Someone who understands what this code is supposed to do should probably take a proper look. llvm-svn: 116917
* Access control polish: drop the note on the original declaration andJohn McCall2010-10-201-1/+43
| | | | | | say 'implicitly' when it was implicit. Resolves PR 7930 and my peace of mind. llvm-svn: 116916
* Add support for the '--sysroot' flag, and an accompanying test of itsChandler Carruth2010-10-201-0/+9
| | | | | | interactions with -isysroot and other driver commands. llvm-svn: 116912
* When matching template parameter lists to template-ids in a scope specifierJohn McCall2010-10-201-18/+98
| | | | | | | on a friend declaration, skip template-ids which do not depend on the current parameter list. llvm-svn: 116911
* Fix handling of property and ivar lookup in typo correction; the twoDouglas Gregor2010-10-202-58/+68
| | | | | | | kinds of lookup into Objective-C classes were tangled together, a situation that was compounded by automatically synthesized ivars. llvm-svn: 116907
* Add a __has_attribute macro that works much like __has_feature and ↵Anders Carlsson2010-10-202-3/+15
| | | | | | __has_builtin. llvm-svn: 116906
* Introduce a simple cache for unqualified typo corrections, so that weDouglas Gregor2010-10-201-26/+70
| | | | | | | | | | | don't repeatedly loop through identifiers, correcting the same typo'd identifier over and over again. We still bail out after 20 typo corrections, but this should help improve performance in the common case where we're typo-correcting because the user forgot to include a header. llvm-svn: 116901
* Eliminate another ordering dependency in typo correction. Re-enable typo.m, ↵Douglas Gregor2010-10-201-1/+4
| | | | | | which seems to be working properly. llvm-svn: 116894
* Had the wrong type for ArgType. :-( Fixed.Craig Silverstein2010-10-201-1/+1
| | | | llvm-svn: 116893
* The type-to-delete may not be a pointer if it's a dependent type.Craig Silverstein2010-10-201-1/+5
| | | | | | | | | | | | | | | | Here's example code: --- template<class T> class MyClass { struct S { }; S* NewS() { return new S; } void DeleteS() { delete NewS(); } }; --- CXXDeleteExpr::getDestroyedType() on the 'delete NewS()' expression would crash before this change. Now it returns a dependent type object. Solution suggested by dgregor. llvm-svn: 116891
* Fix issue with chained PCH where forward references did not pick up later ↵Argyrios Kyrtzidis2010-10-201-0/+18
| | | | | | definition in the chained PCH. llvm-svn: 116887
OpenPOWER on IntegriCloud