summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST/CommentCommandTraits.cpp
diff options
context:
space:
mode:
authorDmitri Gribenko <gribozavr@gmail.com>2012-09-11 19:22:03 +0000
committerDmitri Gribenko <gribozavr@gmail.com>2012-09-11 19:22:03 +0000
commit9304d863295caee0921ddbb44df0fa3d9870d38e (patch)
treed29519a25340fc567c9644cd53227b442b2cf63e /clang/lib/AST/CommentCommandTraits.cpp
parent1778831a3d1d24ab6545635f63da4d9c5f8f0ac7 (diff)
downloadbcm5719-llvm-9304d863295caee0921ddbb44df0fa3d9870d38e.tar.gz
bcm5719-llvm-9304d863295caee0921ddbb44df0fa3d9870d38e.zip
Comment parsing: handle non-builtin commands correctly. After semantic
analysis registers a command, it becomes a "known" command for the lexer, since it has an ID. Having this freedom of choice to register a command is a good thing since BriefParser does not need this. But the parser should still invoke the correct semantic analysis method (actOnUnknownCommand) in this case. llvm-svn: 163646
Diffstat (limited to 'clang/lib/AST/CommentCommandTraits.cpp')
-rw-r--r--clang/lib/AST/CommentCommandTraits.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/AST/CommentCommandTraits.cpp b/clang/lib/AST/CommentCommandTraits.cpp
index ba0aa9ae12e..e7e40fd1090 100644
--- a/clang/lib/AST/CommentCommandTraits.cpp
+++ b/clang/lib/AST/CommentCommandTraits.cpp
@@ -40,6 +40,7 @@ const CommandInfo *CommandTraits::registerUnknownCommand(StringRef CommandName)
CommandInfo *Info = new (Allocator) CommandInfo();
Info->Name = Name;
Info->ID = NextID++;
+ Info->IsUnknownCommand = true;
RegisteredCommands.push_back(Info);
OpenPOWER on IntegriCloud