This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rGbfb4afee74c8: [clang-format] Avoid inserting space after C++
casts. (authored by curdeius).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAS
curdeius requested review of this revision.
curdeius added a comment.
I took another approach to fix the problem found in polly tests.
I added CppCastLParen kind so as not to interfere with C-style casts.
I also added a test case taken from lib/Format that got misformatted by the
previous version
curdeius updated this revision to Diff 410638.
curdeius added a comment.
This revision is now accepted and ready to land.
- Fix. Add tests from inspired by polly and lib/Format that had misformats.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D12014
curdeius planned changes to this revision.
curdeius added a comment.
This commit provokes failures in formatting tests of polly.
Cf. https://lab.llvm.org/buildbot/#/builders/205/builds/3320.
That's probably because of ) being annotated as CastRParen instead of Unknown
before, hence being kept on
This revision was automatically updated to reflect the committed changes.
curdeius marked an inline comment as done.
Closed by commit rGe021987273be: [clang-format] Avoid inserting space after C++
casts. (authored by curdeius).
Changed prior to commit:
https://reviews.llvm.org/D120140?vs=409959
curdeius marked an inline comment as done.
curdeius added inline comments.
Comment at: clang/lib/Format/TokenAnnotator.cpp:1951
+// FIXME: Maybe we should handle identifiers ending with "_cast",
+// e.g. bit_cast?
+return true;
lichray added inline comments.
Comment at: clang/lib/Format/TokenAnnotator.cpp:1951
+// FIXME: Maybe we should handle identifiers ending with "_cast",
+// e.g. bit_cast?
+return true;
Very unlikely `bit_cast` gives you somethin
curdeius added inline comments.
Comment at: clang/lib/Format/TokenAnnotator.cpp:1740
+assert(Current.MatchingParen);
+Current.MatchingParen->setType(TT_Unknown);
+ }
To add some context, in the failing cases, the opening parenthesis was set t
curdeius created this revision.
curdeius added reviewers: MyDeveloperDay, HazardyKnusperkeks, owenpan.
curdeius requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
Fixes https://github.com/llvm/llvm-project/issues/53876.
This is a solution for