Normal indent for last element of builder-type call.
authorDaniel Jasper <djasper@google.com>
Fri, 1 Mar 2013 16:48:32 +0000 (16:48 +0000)
committerDaniel Jasper <djasper@google.com>
Fri, 1 Mar 2013 16:48:32 +0000 (16:48 +0000)
commitf9a84b5f577dda8468f471ba2e2e5791f9962ce1
tree0535565c4ffdc78eda5008758722ca180a48011a
parent3324cbefcde82930503483819cf76077192840d2
Normal indent for last element of builder-type call.

In builder type call, we indent to the laster function calls.
However, for the last element of such a call, we don't need to do
so, as that normally just wastes space and does not increase
readability.

Before:
aaaaaa->aaaaaa->aaaaaa( // break
                  aaaaaa);
aaaaaaaaaaaaaaaaaaaaa->aaaaaaaaaaaaaaaaaaaaaa
    ->aaaaaaaaaaaaaaaaaaaaaaaaaa(
        aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa);

After:
aaaaaa->aaaaaa->aaaaaa( // break
    aaaaaa);
aaaaaaaaaaaaaaaaaaaaa->aaaaaaaaaaaaaaaaaaaaaa->aaaaaaaaaaaaaaaaaaaaaaaaaa(
    aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa);

llvm-svn: 176352
clang/lib/Format/Format.cpp
clang/lib/Format/TokenAnnotator.cpp
clang/lib/Format/TokenAnnotator.h
clang/unittests/Format/FormatTest.cpp