[PATCH] D121754: [clang-format] Refactor determineStarAmpUsage
MyDeveloperDay via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Mar 18 01:54:57 PDT 2022
MyDeveloperDay requested changes to this revision.
MyDeveloperDay added inline comments.
This revision now requires changes to proceed.
================
Comment at: clang/lib/Format/TokenAnnotator.cpp:2146-2147
+ // know how they can be followed by a star or amp.
+ // co_await, delete - It doesn't make sense to have them followed by a unary
+ // `+` or `-`.
+ if (PrevToken->isOneOf(TT_ConditionalExpr, tok::l_paren, tok::comma,
----------------
HazardyKnusperkeks wrote:
> Especially here, why should a `+` after `delete` be a binary operator?
> How much sense it makes doesn't matter, it is valid c++: https://gcc.godbolt.org/z/c1x1nn3Ej
I'm also trying to understand did you mean you couldn't have
case -1:
case +1:
case +0:
case -0:
https://gcc.godbolt.org/z/qvE44d5xz
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D121754/new/
https://reviews.llvm.org/D121754
More information about the cfe-commits
mailing list