summaryrefslogtreecommitdiffstats
path: root/clang/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* Make the Objective-C checker look for subclasses of NSString instead of just ↵Anders Carlsson2011-03-081-13/+14
| | | | | | NSString and NSMutableString. llvm-svn: 127268
* Clarify the context in which an Objective-C type name is being parsedDouglas Gregor2011-03-081-6/+9
| | | | | | | by using an enumeration rather than a boolean value. No functionality change. llvm-svn: 127259
* Warn on usage of unavailable objc 'class' inFariborz Jahanian2011-03-082-1/+2
| | | | | | varienty of cases. // rdar://9092208 llvm-svn: 127257
* Teach libclang's token-annotation logic about context-sensitiveDouglas Gregor2011-03-087-13/+32
| | | | | | keywords for Objective-C+ and C++0x. llvm-svn: 127253
* Fixed source range for StaticAssertDecl and LinkageSpecDecl. Fixed source ↵Abramo Bagnara2011-03-0810-30/+125
| | | | | | range for declarations using postfix types. llvm-svn: 127251
* When writing file references in a pch, make sure to ask the file manager for ↵Anders Carlsson2011-03-081-0/+7
| | | | | | the absolute path. llvm-svn: 127248
* Fixed NamespaceDecl source range.Abramo Bagnara2011-03-086-16/+21
| | | | llvm-svn: 127242
* lib/Basic/Targets.cpp: mingw-w64 should define __MINGW32__, too.NAKAMURA Takumi2011-03-081-0/+1
| | | | llvm-svn: 127238
* Fixed bitfields source range.Abramo Bagnara2011-03-081-0/+5
| | | | llvm-svn: 127237
* Emit block capture initializers as if they were normal initializers for a localJohn McCall2011-03-081-1/+3
| | | | | | variable that just happens to be stored in a wierd place. llvm-svn: 127235
* Extract a function to emit an arbitrary expression as if it were the initializerJohn McCall2011-03-082-54/+84
| | | | | | for a local variable. llvm-svn: 127227
* Fixed source range for all DeclaratorDecl's.Abramo Bagnara2011-03-0822-190/+278
| | | | llvm-svn: 127225
* Removed trailing whitespace as a test commitJohn Wiegley2011-03-081-1/+1
| | | | llvm-svn: 127223
* Fix my earlier commit to work with escaped newlines and leave breadcrumbsJohn McCall2011-03-085-20/+75
| | | | | | | in case we want to make a world where we can check intermediate instantiations for this kind of breadcrumb. llvm-svn: 127221
* objc_gc wants a pointer type, not a function type; give it a more appropriate John McCall2011-03-081-10/+42
| | | | | | | | diagnostic. Also, these attributes are commonly written with macros which we actually pre-define, so instead of expanding the macro location, refer to the instantiation location and name it using the macro loc. llvm-svn: 127219
* Update the check for a NULL macro to use Preprocessor::getSpelling().John McCall2011-03-081-5/+3
| | | | llvm-svn: 127217
* Add an API call to retrieve the spelling data of a token from its ↵John McCall2011-03-081-0/+10
| | | | | | SourceLocation. llvm-svn: 127216
* Detect attempts to provide a specialization of a function within aDouglas Gregor2011-03-081-3/+8
| | | | | | dependent scope and produce an error (rather than crashing). Fixes PR8979. llvm-svn: 127206
* When we adjust the inline ASM type, we need to take into account an earlyBill Wendling2011-03-071-1/+1
| | | | | | | | clobber with the 'y' constraint. Otherwise, we get the wrong return type and an assert, because it created a '<1 x i64>' vector type instead of the x86_mmx type. llvm-svn: 127185
* Allow passing '-###' to ASTUnit::LoadFromCommandLine to print out the cc1 ↵Argyrios Kyrtzidis2011-03-071-0/+8
| | | | | | options. llvm-svn: 127183
* Fix null dereference in CFGBlock::FilterEdge that was reported in PR 9412.Ted Kremenek2011-03-071-5/+5
| | | | llvm-svn: 127176
* CodeGenFunction::GenerateBlockFunction() should initialize DebugInfo just ↵Devang Patel2011-03-071-1/+4
| | | | | | like CodeGenFunction::GenerateCode() llvm-svn: 127174
* g++ is more permissive regarding flexible arrays.Argyrios Kyrtzidis2011-03-071-5/+12
| | | | | | | | It will accept flexible array in union and also as the sole element of a struct/class. Fixes rdar://9065507. llvm-svn: 127171
* DebugInfo can be enabled or disabled at function level (e.g. using an ↵Devang Patel2011-03-078-20/+21
| | | | | | attribute). However, at module level it is determined by command line option and the state of command line option does not change during compilation. Make this layering explicit and fix accidental cases where the code generator was checking whether module has debug info enabled instead of checking whether debug info is enabled for this function or not. llvm-svn: 127165
* Do not emit stop point for CXXDefaultArgExpr. It results in suboptimial user ↵Devang Patel2011-03-074-4/+17
| | | | | | | | | | | | | experience. 21 int main() { 22 A a; For example, here user would expect to stop at line 22, even if A's constructor leads to a call through CXXDefaultArgExpr. This fixes ostream-defined.exp regression from gdb testsuite. llvm-svn: 127164
* Support explicit template specialization and instantiation for membersDouglas Gregor2011-03-072-12/+25
| | | | | | | | | | | of a C++0x inline namespace within enclosing namespaces, as noted in C++0x [namespace.def]p8. Fixes <rdar://problem/9006349>, a libc++ failure where Clang was rejected an explicit specialization of std::swap (since libc++ puts it into an inline, versioned namespace std::__1). llvm-svn: 127162
* When rebuilding a dependent template specialization type to anotherDouglas Gregor2011-03-071-3/+4
| | | | | | | dependent template specialization type, make sure to set the keyword location. Fixes some valgrind issues introduced in r127150. llvm-svn: 127159
* The conditional needs to be pushed before the branch. Make the test lessJohn McCall2011-03-072-78/+85
| | | | | | trivial to check this. Adjust for style. llvm-svn: 127151
* When transforming a dependent template specialization type, make sureDouglas Gregor2011-03-071-5/+18
| | | | | | | | | to set the source-location information for the template arguments to the *transformed* source-location information, not the original source-location information. Fixes <rdar://problem/8986308> (a libc++ SFINAE issue) and the Boost.Polygon failure. llvm-svn: 127150
* Produce a diagnostic for unused overloaded expressions, from Faisal Vali!Douglas Gregor2011-03-071-0/+23
| | | | llvm-svn: 127148
* An operator new with an empty exception specifier returns null on a badJohn McCall2011-03-071-0/+8
| | | | | | | | allocation and therefore requires a null-check. We were doing that, but we weren't treating the new-initializer as being conditionally executed, which means it was possible to get ill-formed IR as in PR9298. llvm-svn: 127147
* Check in the implementation as well...Anders Carlsson2011-03-071-3/+7
| | | | llvm-svn: 127144
* Redo part of r127137:Joerg Sonnenberger2011-03-071-5/+5
| | | | | | | | Pass down the correct C->getArgs, but keep it with the original DerivedArgList type. Slightly adjust the MakeIndex call for the different base type. This unbreaks the handling of --no-mangle on Darwin. llvm-svn: 127142
* Remove the AST printer (-ast-print-xml), which is too incomplete andDouglas Gregor2011-03-079-855/+0
| | | | | | | | | | | | | | | too low-level to actually be useful but is just interesting enough for people to try to use it (which won't actually work beyond toy examples). To bring back the AST printer, it needs to be: - Complete, covering all of C/C++/Objective-C - Documented, with appropriate Schema against which we can validate the output - Designed for C/C++/Objective-C, not Clang's specific ASTs - Stable across Clang versions - Well-tested llvm-svn: 127141
* Explicitly initialize CCCIsCPPJoerg Sonnenberger2011-03-071-2/+2
| | | | llvm-svn: 127139
* If called as *cpp or *cpp-[^-]*, run only the preprocessor. If noJoerg Sonnenberger2011-03-062-8/+18
| | | | | | | input is specified, use stdin implicitly. Based on a patch from Roman Divacky. llvm-svn: 127137
* Revert r126422 "Use private linkage to avoid symbol conflicts inDouglas Gregor2011-03-061-1/+1
| | | | | | corner cases like the one in PR9301." which caused PR9416. llvm-svn: 127136
* Used a nicer cast.Abramo Bagnara2011-03-061-1/+1
| | | | llvm-svn: 127134
* Convert FileManager::FixupRelativePath over to using PathV2.Anders Carlsson2011-03-062-17/+22
| | | | llvm-svn: 127133
* Improved type source location for long long type.Abramo Bagnara2011-03-061-4/+6
| | | | llvm-svn: 127132
* We may fail to map a declaration in a template to its instantiatedDouglas Gregor2011-03-061-7/+26
| | | | | | | | | | | declaration because of interesting ordering dependencies while instantiating a class template or member class thereof. Complain, rather than asserting (+Asserts) or silently rejecting the code (-Asserts). Fixes the crash-on-invalid in PR8965. llvm-svn: 127129
* Fix driver for thumb-capable ARM hosts, from Mikko Lehtonen!Douglas Gregor2011-03-062-6/+11
| | | | llvm-svn: 127128
* Write CXX base specifier offsets for chained ASTs.Anders Carlsson2011-03-061-19/+27
| | | | llvm-svn: 127126
* When serializing a DeclRefExpr, always store the number of explicit templateAnders Carlsson2011-03-062-10/+12
| | | | | | | | arguments at the same offset, since it's needed when creating the empty DeclRefExpr when deserializing. Fixes a memory corruption issue that would lead to random bugs and crashes. llvm-svn: 127125
* Add MinGW GCC 4.5.2 include paths, from Matthieu MonrocqDouglas Gregor2011-03-061-0/+3
| | | | llvm-svn: 127124
* Fix copy-and-paste typo in the transformation of Microsoft __uuidof ↵Douglas Gregor2011-03-061-1/+1
| | | | | | expressions, from Eric Niebler via John Wiegley llvm-svn: 127123
* Correctly unwrap 'auto' types. Fixes PR9414.Anders Carlsson2011-03-061-0/+3
| | | | llvm-svn: 127121
* Completed source ranges fixes for all classes inheriting from TypeDecl.Abramo Bagnara2011-03-065-12/+8
| | | | llvm-svn: 127120
* Fixed TypedefDecl and TemplateTypeParameter source range.Abramo Bagnara2011-03-0612-24/+41
| | | | llvm-svn: 127119
* Reinstate r127112, "Propagate new-style exception spec information to ↵Sebastian Redl2011-03-069-35/+37
| | | | | | ExtProtoInfo.", this time with the missing header. llvm-svn: 127118
OpenPOWER on IntegriCloud