[PATCH] D91245: [clang-format] Recognize c++ coroutine keywords as unary operator to avoid misleading pointer alignment

Chuanqi Xu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Dec 14 23:42:08 PST 2020


ChuanqiXu added inline comments.


================
Comment at: clang/unittests/Format/FormatTest.cpp:7759-7761
+  // The default setting for PointerAlignment is PAS_Right.
+  // But if we set PointerAlignment as PAS_Left, the formatter
+  // would mis-format the pointer alignment.
----------------
HazardyKnusperkeks wrote:
> I don't think this should be in the tests, because it is not true (if your patch works).
I'm confusing about your comment. What is not true? Do you mean if my patch works then the `co_return *a;` should be formatted as `co_return* a`?


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

https://reviews.llvm.org/D91245



More information about the cfe-commits mailing list