This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rG3362fa59ec40: [clang-format] extern with new line brace
without indentation (authored by MyDeveloperDay).
Repository:
rG LLVM Github Monorepo
CHA
owenpan accepted this revision.
owenpan added a comment.
LGTM!
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D115879/new/
https://reviews.llvm.org/D115879
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/m
MyDeveloperDay updated this revision to Diff 395166.
MyDeveloperDay marked 4 inline comments as done.
MyDeveloperDay added a comment.
Address nits and review comments (remove unnecessary lines)
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D115879/new/
https://reviews.llvm.org/D115879
F
owenpan accepted this revision.
owenpan added inline comments.
Comment at: clang/lib/Format/UnwrappedLineParser.cpp:1291-1293
+((Style.IndentExternBlock == FormatStyle::IEBS_Indent) ||
+ (Style.BraceWrapping.AfterExternBlock &&
+ Style.IndentE
curdeius accepted this revision.
curdeius added a comment.
This revision is now accepted and ready to land.
LGTM!
Comment at: clang/lib/Format/UnwrappedLineParser.cpp:1285-1287
+if (Style.BraceWrapping.AfterExternBlock) {
+ addUnwrappedLine();
}
--
MyDeveloperDay marked 7 inline comments as done.
MyDeveloperDay added inline comments.
Comment at: clang/lib/Format/UnwrappedLineParser.cpp:1282-1300
if (FormatTok->Tok.is(tok::string_literal)) {
nextToken();
if (FormatTok->Tok.is(tok::l_brace)) {
+if (
MyDeveloperDay updated this revision to Diff 395088.
MyDeveloperDay added a comment.
As always you are both correct
- tidy up the unit tests to follow our pattern
- reduce unnecessary style setting
- try and tidy up the indent selection a little
CHANGES SINCE LAST ACTION
https://reviews.llvm.
curdeius added inline comments.
Comment at: clang/unittests/Format/FormatTest.cpp:3819
+ Style.IndentExternBlock = FormatStyle::IEBS_NoIndent;
+ verifyFormat("extern \"C\"\n{ /*13*/\n}", Style);
+ verifyFormat("extern \"C\"\n{\n"
owenpan wrote:
> curdeius wrot
owenpan added inline comments.
Comment at: clang/unittests/Format/FormatTest.cpp:3816
+ Style.IndentExternBlock = FormatStyle::IEBS_AfterExternBlock;
+ Style.BreakBeforeBraces = FormatStyle::BS_Custom;
+ Style.BraceWrapping.AfterExternBlock = true;
This line i
owenpan added inline comments.
Comment at: clang/lib/Format/UnwrappedLineParser.cpp:1282-1300
if (FormatTok->Tok.is(tok::string_literal)) {
nextToken();
if (FormatTok->Tok.is(tok::l_brace)) {
+if (Style.BraceWrapping.AfterExternBlock) {
+ addUn
owenpan added inline comments.
Comment at: clang/unittests/Format/FormatTest.cpp:3819
+ Style.IndentExternBlock = FormatStyle::IEBS_NoIndent;
+ verifyFormat("extern \"C\"\n{ /*13*/\n}", Style);
+ verifyFormat("extern \"C\"\n{\n"
curdeius wrote:
> I'd prefer th
curdeius requested changes to this revision.
curdeius added inline comments.
This revision now requires changes to proceed.
Comment at: clang/unittests/Format/FormatTest.cpp:3815
+
+ Style.IndentExternBlock = FormatStyle::IEBS_AfterExternBlock;
+ Style.BreakBeforeBraces = Forma
MyDeveloperDay created this revision.
MyDeveloperDay added reviewers: HazardyKnusperkeks, curdeius, owenpan,
MarcusJohnson91.
MyDeveloperDay added projects: clang, clang-format.
MyDeveloperDay requested review of this revision.
https://github.com/llvm/llvm-project/issues/49804
Interaction betwee
13 matches
Mail list logo