jaredgrubb marked 2 inline comments as done.
jaredgrubb added inline comments.
Herald added a subscriber: wangpc.
Herald added a reviewer: rymiel.


================
Comment at: clang/lib/Format/UnwrappedLineParser.cpp:1779-1782
         nextToken();
+        // Return types: pointers are ok too.
+        while (FormatTok->is(tok::star))
+          nextToken();
----------------
owenpan wrote:
> 
I think this obscures the logic a bit. The first one is to consume one token 
(the return type) and the next is to consume a different kind of token 
(trailing stars). Putting them in a while loop makes it harder to reason about 
why it's looping in that way.


================
Comment at: clang/unittests/Format/FormatTestObjC.cpp:1007-1010
+  Style = getWebKitStyle();
+  verifyFormat("int* p = ^int*() { //\n"
+               "    return nullptr;\n"
+               "}();");
----------------
owenpan wrote:
> 
Fixed!


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D146434

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

Reply via email to