owenpan added inline comments.

================
Comment at: clang/lib/Format/NamespaceEndCommentsFixer.cpp:185-189
+      const FormatToken *Previous = AnnotatedLines[StartLineIndex - 1]->Last;
+      while (Previous && Previous->is(tok::comment)) {
+        Previous = Previous->Previous;
+      }
+      if (Previous && Previous->is(tok::semi))
----------------
Something like below will do:
`  if (AnnotatedLines[StartLineIndex - 1]->endsWith(tok::semi))`


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D115647/new/

https://reviews.llvm.org/D115647

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

Reply via email to