juliehockett added a comment.

Please run clang-format and clang-tidy on the patch.



================
Comment at: clang-tools-extra/clang-doc/ClangDoc.cpp:25
 #include "clang/Frontend/FrontendActions.h"
+#include "Representation.h"
 
----------------
Sort includes (this should be at the top)


================
Comment at: clang-tools-extra/clang-doc/Mapper.cpp:13
 #include "Serialize.h"
+#include "Representation.h"
 #include "clang/AST/Comment.h"
----------------
Sort includes alphabetically, but you shouldn't need this here?


================
Comment at: clang-tools-extra/clang-doc/Mapper.h:23
 #include "clang/Tooling/Execution.h"
+#include "Representation.h"
 
----------------
Sort includes (this should be at the top)


================
Comment at: clang-tools-extra/clang-doc/Serialize.cpp:174
 
-static void parseFields(RecordInfo &I, const RecordDecl *D) {
+static bool isPublic(const clang::AccessSpecifier as, const clang::Linkage 
link){
+    if(as == clang::AccessSpecifier::AS_private)
----------------
clang-tidy will tell you to capitalize these in llvm world (as -> AS, link -> 
Link)


================
Comment at: clang-tools-extra/clang-doc/Serialize.cpp:322-324
+  if(PublicOnly && ! isPublic(D->getAccess(), D->getLinkageInternal())){
+    return "";
+  }
----------------
Since this is the same for Record/Function/Enum, can we move this to 
`populateSymbolInfo()`?

Also, elide braces on single-line ifs.


https://reviews.llvm.org/D48395



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to