Please also update `checkLanguageOptions` in ASTReader.cpp to compare 
CommentOptions, too.


================
Comment at: lib/AST/CommentCommandTraits.cpp:24
@@ +23,3 @@
+
+void CommandTraits::RegisterCommentOptions(
+  const CommentOptions &CommentOptions) {
----------------
Functions' names start with a lowercase letter.

================
Comment at: lib/AST/CommentCommandTraits.cpp:25
@@ +24,3 @@
+void CommandTraits::RegisterCommentOptions(
+  const CommentOptions &CommentOptions) {
+  for (CommentOptions::BlockCommandNamesTy::const_iterator I =
----------------
'const' should be indented by at least 4 spaces.

================
Comment at: lib/Frontend/ASTUnit.cpp:579-580
@@ -576,1 +578,4 @@
+    // constructed, so register them now.
+    Context.getCommentCommandTraits().RegisterCommentOptions(
+      LangOpt.CommentOpts);
   }
----------------
As far as I see, updated() can be called multiple times.  We will get multiple 
commands with the same name registered.

I'm not sure that this is the correct place to put this, though.  Not all PCH 
loading is done through ASTUnit.  CompilerInstance::createPCHExternalASTSource 
might be the correct one, but I'm not sure.  I'll ask Doug.


http://llvm-reviews.chandlerc.com/D272
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to