summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend/DocumentXML.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Remove the AST printer (-ast-print-xml), which is too incomplete andDouglas Gregor2011-03-071-381/+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
* Teach NestedNameSpecifier to keep track of namespace aliases the sameDouglas Gregor2011-02-241-0/+5
| | | | | | | | way it keeps track of namespaces. Previously, we would map from the namespace alias to its underlying namespace when building a nested-name-specifier, losing source information in the process. llvm-svn: 126358
* Make sure to always check the result ofDouglas Gregor2010-11-121-5/+8
| | | | | | | SourceManager::getPresumedLoc(), so that we don't try to make use of an invalid presumed location. Doing so can cause crashes. llvm-svn: 118885
* Appeasing MSVC, take 3Douglas Gregor2010-11-091-0/+1
| | | | llvm-svn: 118493
* Try to appease MSVCDouglas Gregor2010-11-091-0/+4
| | | | llvm-svn: 118487
* Add missing includeDouglas Gregor2010-11-091-0/+1
| | | | llvm-svn: 118485
* sprintf -> snprintf conversion, from Vladimir KirillovDouglas Gregor2010-11-091-1/+1
| | | | llvm-svn: 118478
* Improved -ast-print-xml for C++, from Sebastien Binet!Douglas Gregor2010-05-101-0/+29
| | | | llvm-svn: 103412
* First part of changes to eliminate problems with cv-qualifiers andDouglas Gregor2009-11-161-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | sugared types. The basic problem is that our qualifier accessors (getQualifiers, getCVRQualifiers, isConstQualified, etc.) only look at the current QualType and not at any qualifiers that come from sugared types, meaning that we won't see these qualifiers through, e.g., typedefs: typedef const int CInt; typedef CInt Self; Self.isConstQualified() currently returns false! Various bugs (e.g., PR5383) have cropped up all over the front end due to such problems. I'm addressing this problem by splitting each qualifier accessor into two versions: - the "local" version only returns qualifiers on this particular QualType instance - the "normal" version that will eventually combine qualifiers from this QualType instance with the qualifiers on the canonical type to produce the full set of qualifiers. This commit adds the local versions and switches a few callers from the "normal" version (e.g., isConstQualified) over to the "local" version (e.g., isLocalConstQualified) when that is the right thing to do, e.g., because we're printing or serializing the qualifiers. Also, switch a bunch of Context.getCanonicalType(T1).getUnqualifiedType() == Context.getCanonicalType(T2).getQualifiedType() expressions over to Context.hasSameUnqualifiedType(T1, T2) llvm-svn: 88969
* Refactor the representation of qualifiers to bring ExtQualType out of theJohn McCall2009-09-241-2/+2
| | | | | | | | Type hierarchy. Demote 'volatile' to extended-qualifier status. Audit our use of qualifiers and fix a few places that weren't dealing with qualifiers quite right; many more remain. llvm-svn: 82705
* Change all the Type::getAsFoo() methods to specializations of Type::getAs().John McCall2009-09-211-1/+1
| | | | | | | | | | | Several of the existing methods were identical to their respective specializations, and so have been removed entirely. Several more 'leaf' optimizations were introduced. The getAsFoo() methods which imposed extra conditions, like getAsObjCInterfacePointerType(), have been left in place. llvm-svn: 82501
* Fix spelling.Mike Stump2009-09-161-1/+1
| | | | llvm-svn: 82078
* Remove tabs, and whitespace cleanups.Mike Stump2009-09-091-87/+64
| | | | llvm-svn: 81346
* More XML output support, from Olaf Krzikalla!Douglas Gregor2009-06-151-283/+65
| | | | llvm-svn: 73402
* Refactor and clean up the AST printer, so that it uses a DeclVisitor,Douglas Gregor2009-05-301-0/+2
| | | | | | | | | walks through DeclContexts properly, and prints more of the information available in the AST. The functionality is still available via -ast-print, -ast-dump, etc., and also via the new member functions Decl::dump() and Decl::print(). llvm-svn: 72597
* Create a new PrintingPolicy class, which we pass down through the ASTDouglas Gregor2009-05-291-1/+1
| | | | | | | | | printing logic to help customize the output. For now, we use this rather than a special flag to suppress the "struct" when printing "struct X" and to print the Boolean type as "bool" in C++ but "_Bool" in C. llvm-svn: 72590
* AST XML dump, from Olaf Krzikalla!Douglas Gregor2009-05-211-0/+577
llvm-svn: 72224
OpenPOWER on IntegriCloud