[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-11-28 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. For non-functional clean-ups generally llvm doesn't require pre-commit review - I did communicate here so people involved in the original change wouldn't miss the clean-up. I do agree that what commits to pre-review is a fine line, and usually try to err on the side of p

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-11-26 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks added a comment. In D119138#3951850 , @klimek wrote: > I changed it in 49aca00d63e14df8bc68fc4329e6cbc9c9805eb8 > . > > "We" is the people working on clang-format :)

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-11-26 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. I changed it in 49aca00d63e14df8bc68fc4329e6cbc9c9805eb8 . "We" is the people working on clang-format :) I hope that we have a common goal of making clang-format as easy to maintain as we can. FWIW, I

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-11-26 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks added a comment. In D119138#3951749 , @klimek wrote: > Generally, why do we need to have that much information? I.e. why do we need > to know the exact type of the "requires" keyword? > I do understand we need to know the brace type, b

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-11-26 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. Generally, why do we need to have that much information? I.e. why do we need to know the exact type of the "requires" keyword? I do understand we need to know the brace type, but that seems like it would be easier to figure out in the TokenAnnotator (where we already pars

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-11-25 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. Herald added a project: All. Hey ho, sorry for the late comment here, but adding peekNextToken(n) is problematic, as this gets in the way of future changes we want to do to handle macros better. Usually we want to use X = Tokens->getPosition() and FormatTok = Tokens->set

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-02-15 Thread Björn Schäpers via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGbcd1e4612f4f: [clang-format] Further improve support for requires expressions (authored by HazardyKnusperkeks). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-02-14 Thread Marek Kurdej via Phabricator via cfe-commits
curdeius accepted this revision. curdeius added a comment. This revision is now accepted and ready to land. LGTM! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119138/new/ https://reviews.llvm.org/D119138 ___ cfe-commits mailing list cfe-comm

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-02-12 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks marked 3 inline comments as done. HazardyKnusperkeks added inline comments. Comment at: clang/lib/Format/UnwrappedLineParser.cpp:2835-2841 + // FIXME: We need an annotation on the paren to really know if it is a + // function call: + // ... foo()

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-02-12 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks updated this revision to Diff 408221. HazardyKnusperkeks added a comment. New approach for identifying the expressions. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119138/new/ https://reviews.llvm.org/D119138 Files: clang/lib/Format/UnwrappedLineParser.cpp clan

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-02-12 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks planned changes to this revision. HazardyKnusperkeks added inline comments. Comment at: clang/lib/Format/UnwrappedLineParser.cpp:2835-2841 + // FIXME: We need an annotation on the paren to really know if it is a + // function call: + // ... foo()

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-02-11 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added inline comments. Comment at: clang/lib/Format/UnwrappedLineParser.cpp:2798-2802 +// This one is really tricky, since most tokens doesn't have a type yet. +// The & or && can be binary operators, then we have a requires +// expression. But they also c

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-02-11 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks updated this revision to Diff 408028. HazardyKnusperkeks marked 6 inline comments as done. HazardyKnusperkeks added a comment. Rebased and updated CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119138/new/ https://reviews.llvm.org/D119138 Files: clang/lib/Format/Unw

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-02-07 Thread Marek Kurdej via Phabricator via cfe-commits
curdeius added a comment. Some nits. Comment at: clang/lib/Format/UnwrappedLineParser.cpp:1541-1542 +case tok::kw_requires: { + bool Return = parseRequires(); + if (Return) +return; Comment at: clang/lib/Format/Unwrappe

[PATCH] D119138: [clang-format] Further improve support for requires expressions

2022-02-07 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks created this revision. HazardyKnusperkeks added reviewers: MyDeveloperDay, curdeius, owenpan. HazardyKnusperkeks added a project: clang-format. HazardyKnusperkeks requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Detect req