]> granicus.if.org Git - clang/commitdiff
Add declarations nested in a linkage specification to the output of
authorDouglas Gregor <dgregor@apple.com>
Mon, 18 Oct 2010 14:35:28 +0000 (14:35 +0000)
committerDouglas Gregor <dgregor@apple.com>
Mon, 18 Oct 2010 14:35:28 +0000 (14:35 +0000)
-ast-print-xml, from Martin Vejnar!

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116702 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Frontend/DeclXML.def
lib/Frontend/DeclXML.cpp

index 29135e6293feeadecb82bd23af054defdf3b0ed2..1b158fdfafc01b0bbc17e9a5516a053f2c7ddfc9 100644 (file)
@@ -320,6 +320,7 @@ NODE_XML(LinkageSpecDecl, "LinkageSpec")
          ENUM_XML(LinkageSpecDecl::lang_c, "C")
          ENUM_XML(LinkageSpecDecl::lang_cxx, "CXX")
   END_ENUM_XML
+  SUB_NODE_XML(DeclContext)
 END_NODE_XML
 
 NODE_XML(TemplateDecl, "Template")
index c688ed043e87625897ddd28761da588e56168fe2..8d3d225a4b38bec86b58523c1c2c5fc2fbcde1e8 100644 (file)
@@ -104,7 +104,7 @@ class DocumentXML::DeclPrinter : public DeclVisitor<DocumentXML::DeclPrinter> {
       Doc.PrintStmt(argDecl->getDefaultArg());
   }
 
-  void addSubNodes(NamespaceDecl* ns) {
+  void addSubNodes(DeclContext* ns) {
 
     for (DeclContext::decl_iterator 
            d    = ns->decls_begin(),