diff options
author | Dmitri Gribenko <gribozavr@gmail.com> | 2012-07-06 00:28:32 +0000 |
---|---|---|
committer | Dmitri Gribenko <gribozavr@gmail.com> | 2012-07-06 00:28:32 +0000 |
commit | ec92531c292e9c6961dd3e545c9fb031135b19bc (patch) | |
tree | 2c344abf5dbc2547b3b0159880de0196461572e2 /clang/utils/TableGen/TableGen.cpp | |
parent | d5200f1bc4cb41329fd05a09d552e63705b294fc (diff) | |
download | bcm5719-llvm-ec92531c292e9c6961dd3e545c9fb031135b19bc.tar.gz bcm5719-llvm-ec92531c292e9c6961dd3e545c9fb031135b19bc.zip |
Implement AST classes for comments, a real parser for Doxygen comments and a
very simple semantic analysis that just builds the AST; minor changes for lexer
to pick up source locations I didn't think about before.
Comments AST is modelled along the ideas of HTML AST: block and inline content.
* Block content is a paragraph or a command that has a paragraph as an argument
or verbatim command.
* Inline content is placed within some block. Inline content includes plain
text, inline commands and HTML as tag soup.
llvm-svn: 159790
Diffstat (limited to 'clang/utils/TableGen/TableGen.cpp')
-rw-r--r-- | clang/utils/TableGen/TableGen.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/utils/TableGen/TableGen.cpp b/clang/utils/TableGen/TableGen.cpp index d98cc72cf84..d3408ed20f4 100644 --- a/clang/utils/TableGen/TableGen.cpp +++ b/clang/utils/TableGen/TableGen.cpp @@ -38,6 +38,7 @@ enum ActionType { GenClangDiagsDefs, GenClangDiagGroups, GenClangDiagsIndexName, + GenClangCommentNodes, GenClangDeclNodes, GenClangStmtNodes, GenClangSACheckers, @@ -86,6 +87,8 @@ namespace { clEnumValN(GenClangDiagsIndexName, "gen-clang-diags-index-name", "Generate Clang diagnostic name index"), + clEnumValN(GenClangCommentNodes, "gen-clang-comment-nodes", + "Generate Clang AST comment nodes"), clEnumValN(GenClangDeclNodes, "gen-clang-decl-nodes", "Generate Clang AST declaration nodes"), clEnumValN(GenClangStmtNodes, "gen-clang-stmt-nodes", @@ -148,6 +151,9 @@ public: case GenClangDiagsIndexName: EmitClangDiagsIndexName(Records, OS); break; + case GenClangCommentNodes: + EmitClangASTNodes(Records, OS, "Comment", ""); + break; case GenClangDeclNodes: EmitClangASTNodes(Records, OS, "Decl", "Decl"); EmitClangDeclContext(Records, OS); |