[PATCH] D82199: [clang-format] restore indent in conditionals when AlignOperands is DontAlign

Krasimir Georgiev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jun 24 03:44:57 PDT 2020


krasimir updated this revision to Diff 272957.
krasimir marked an inline comment as done.
krasimir added a comment.

- add a FIXME


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D82199

Files:
  clang/unittests/Format/FormatTest.cpp


Index: clang/unittests/Format/FormatTest.cpp
===================================================================
--- clang/unittests/Format/FormatTest.cpp
+++ clang/unittests/Format/FormatTest.cpp
@@ -6284,6 +6284,10 @@
 
   Style.AlignOperands = FormatStyle::OAS_DontAlign;
   Style.BreakBeforeTernaryOperators = false;
+  // FIXME: Aligning the question marks is weird given DontAlign.
+  // Consider disabling this alignment in this case. Also check whether this
+  // will render the adjustment from https://reviews.llvm.org/D82199
+  // unnecessary.
   verifyFormat("int x = aaaaaaaaaaaaaaa ? aaaaaaaaaaaaaaaaaa :\n"
                "    bbbb                ? cccccccccccccccccc :\n"
                "                          ddddd;\n",


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D82199.272957.patch
Type: text/x-patch
Size: 743 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200624/9cd6328b/attachment-0001.bin>


More information about the cfe-commits mailing list