]> granicus.if.org Git - clang/commit
clang-format: Respect BinPackParameters in Cpp11BracedListStyle.
authorDaniel Jasper <djasper@google.com>
Thu, 17 Apr 2014 11:32:02 +0000 (11:32 +0000)
committerDaniel Jasper <djasper@google.com>
Thu, 17 Apr 2014 11:32:02 +0000 (11:32 +0000)
commit343f33f4e7ea44c8c55024c65c4af0abd2c50956
tree4a1c6e30583e456e820dc4cb338cd5277a424a42
parent594e55be0ecb4c1dff6dea9762c5b2f36d7bb0a2
clang-format: Respect BinPackParameters in Cpp11BracedListStyle.

With BinPackParameters=false and Cpp11BracedListStyle=true (i.e. mostly
for Chromium):

Before:
  const Aaaaaa aaaaa = {aaaaa, bbbbb,  ccccc,  ddddd,  eeeee, ffffff,
                        ggggg, hhhhhh, iiiiii, jjjjjj, kkkkkk};

After:
  const Aaaaaa aaaaa = {aaaaa,
                        bbbbb,
                        ccccc,
                        ddddd,
                        eeeee,
                        ffffff,
                        ggggg,
                        hhhhhh,
                        iiiiii,
                        jjjjjj,
                        kkkkkk};

This fixes llvm.org/PR19359. I am not sure we'll want this in all cases
in the long run, but I'll guess we'll get feedback on that.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@206458 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Format/ContinuationIndenter.cpp
lib/Format/FormatToken.cpp
unittests/Format/FormatTest.cpp