]> granicus.if.org Git - clang/commit
clang-format: Don't merge short else blocks.
authorDaniel Jasper <djasper@google.com>
Thu, 30 Apr 2015 09:24:17 +0000 (09:24 +0000)
committerDaniel Jasper <djasper@google.com>
Thu, 30 Apr 2015 09:24:17 +0000 (09:24 +0000)
commit2f67613c4fb0ab4bb24fc49e45a605a392e0a28c
tree4f049e63791a746cb1a791fa6bed19c12db022af
parenteea23db6de171557adc8110411e1afd0bbaa91a7
clang-format: Don't merge short else blocks.

Before (with the appropriate flags settings):
  if (a) {
    f();
  } else { g(); }

Before (with other appropriate flags settings):
  if (a) { f(); } else {
    g();
  }

After:
  if (a) {
    f();
  } else {
    g();
  }

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