summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST/ASTDiagnostic.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* More ArrayRef-ification of methods.Bill Wendling2012-02-221-5/+4
| | | | llvm-svn: 151152
* Change the checks in the type aka printing. A confusing case where the stringRichard Trieu2011-11-141-3/+10
| | | | | | | | of the first type is the same as the aka string of the second type, but both types are different. Update the logic to print an aka for the first type to show that they are different. llvm-svn: 144558
* When 'bool' is not a built-in type but is defined as a macro, printDouglas Gregor2011-09-271-8/+8
| | | | | | | 'bool' rather than '_Bool' within types, to make things a bit more readable. Fixes <rdar://problem/10063263>. llvm-svn: 140650
* Rename Diagnostic to DiagnosticsEngine as per issue 5397David Blaikie2011-09-251-9/+9
| | | | llvm-svn: 140478
* Switch assert(0/false) llvm_unreachable.David Blaikie2011-09-231-1/+1
| | | | llvm-svn: 140367
* Improve the diagnostic text for -Wmissing-noreturn to include the nameChandler Carruth2011-08-311-2/+2
| | | | | | | | | | | | | | of the function in question when applicable (that is, not for blocks). Patch by Joerg Sonnenberger with some stylistic tweaks by me. When discussing this weth Joerg, streaming the decl directly into the diagnostic didn't work because we have a pointer-to-const, and the overload doesn't accept such. In order to make my style tweaks to the patch, I first changed the overload to accept a pointer-to-const, and then changed the diagnostic printing layer to also use a pointer-to-const, cleaning up a gross line of code along the way. llvm-svn: 138854
* remove unneeded llvm:: namespace qualifiers on some core types now that ↵Chris Lattner2011-07-231-4/+4
| | | | | | | | LLVM.h imports them into the clang namespace. llvm-svn: 135852
* Apply patch from Richard Trieu to fix PR9548:Chandler Carruth2011-07-111-19/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When two different types has the same text representation in the same diagnostic message, print an a.k.a. after the type if the a.k.a. gives extra information about the type. class versa_string; typedef versa_string string; namespace std {template <typename T> class vector;} using std::vector; void f(vector<string> v); namespace std { class basic_string; typedef basic_string string; template <typename T> class vector {}; void g() { vector<string> v; f(v); } } Old message: ---------------- test.cc:15:3: error: no matching function for call to 'f' f(&v); ^ test.cc:7:6: note: candidate function not viable: no known conversion from 'vector<string>' to 'vector<string>' for 1st argument void f(vector<string> v); ^ 1 error generated. New message: --------------- test.cc:15:3: error: no matching function for call to 'f' f(v); ^ test.cc:7:6: note: candidate function not viable: no known conversion from 'vector<string>' (aka 'std::vector<std::basic_string>') to 'vector<string>' (aka 'std::vector<versa_string>') for 1st argument void f(vector<string> v); ^ 1 error generated. llvm-svn: 134904
* Implement support for C++0x alias templates.Richard Smith2011-05-051-3/+5
| | | | llvm-svn: 130953
* Support for C++11 (non-template) alias declarations.Richard Smith2011-04-151-1/+1
| | | | llvm-svn: 129567
* Make AttributedTypes for GC-qualified types and fix some miscellaneousJohn McCall2011-03-041-0/+5
| | | | | | | bugs with such types. Not sure this is quite how I want the desugaring and a.k.a. logic to go, but it suffices. llvm-svn: 126986
* Implement the C++0x deduced 'auto' feature.Richard Smith2011-02-201-7/+15
| | | | | | This fixes PR 8738, 9060 and 9132. llvm-svn: 126069
* Add some tests for reference-collapsing and referencing bindingDouglas Gregor2011-01-201-0/+3
| | | | | | | | | involving rvalue references, to start scoping out what is and what isn't implemented. In the process, tweak some standards citations, type desugaring, and teach the tentative parser about && in ptr-operator. llvm-svn: 123913
* Added ParenType type node.Abramo Bagnara2010-12-101-1/+5
| | | | llvm-svn: 121488
* It's kindof silly that ExtQuals has an ASTContext&, and we can use thatJohn McCall2010-12-101-1/+1
| | | | | | | | | | space better. Remove this reference. To make that work, change some APIs (most importantly, getDesugaredType()) to take an ASTContext& if they need to return a QualType. Simultaneously, diminish the need to return a QualType by introducing some useful APIs on SplitQualType, which is just a std::pair<const Type *, Qualifiers>. llvm-svn: 121478
* revise r112365 to fix the actual problem: the isa<TagType>(Underlying)Chris Lattner2010-09-041-15/+12
| | | | | | | check in the "typedef for anonymous type" check should have been a getAs. llvm-svn: 113085
* suppress annoying textual repetition as 'aka'Gabor Greif2010-08-281-4/+7
| | | | llvm-svn: 112365
* Teach the AKA calculation to look at sugar on the pointee type for pointers andChandler Carruth2010-05-131-64/+69
| | | | | | | | references. This is a WIP as we should handle function pointers, etc. Reshuffle the code to do this to facilitate recursing in this manner, and to check for the type already being printed first rather than last. llvm-svn: 103712
* Merged Elaborated and QualifiedName types.Abramo Bagnara2010-05-111-6/+0
| | | | llvm-svn: 103517
* Make the InjectedClassNameType the canonical type of the current instantiationJohn McCall2010-04-271-6/+0
| | | | | | | | | | | | | | | | of a class template or class template partial specialization. That is to say, in template <class T> class A { ... }; or template <class T> class B<const T*> { ... }; make 'A<T>' and 'B<const T*>' sugar for the corresponding InjectedClassNameType when written inside the appropriate context. This allows us to track the current instantiation appropriately even inside AST routines. It also allows us to compute a DeclContext for a type much more efficiently, at some extra cost every time we write a template specialization (which can be optimized, but I've left it simple in this patch). llvm-svn: 102407
* Create a new InjectedClassNameType to represent bare-word references to the John McCall2010-03-101-0/+6
| | | | | | | | | | | | | injected class name of a class template or class template partial specialization. This is a non-canonical type; the canonical type is still a template specialization type. This becomes the TypeForDecl of the pattern declaration, which cleans up some amount of code (and complicates some other parts, but whatever). Fixes PR6326 and probably a few others, primarily by re-establishing a few invariants about TypeLoc sizes. llvm-svn: 98134
* Move the diagnostic argument formatting function out of Sema and makeDouglas Gregor2010-02-091-0/+266
it available within the AST library, of which Sema is one client. No functionality change. llvm-svn: 95701
OpenPOWER on IntegriCloud