diff options
| author | Daniel Jasper <djasper@google.com> | 2014-01-28 20:13:43 +0000 |
|---|---|---|
| committer | Daniel Jasper <djasper@google.com> | 2014-01-28 20:13:43 +0000 |
| commit | 559b63cbb94e7027fe73df929d63703a1a3bc0c9 (patch) | |
| tree | dd642652efd641c3e614fc1d688f15e6a77d74d7 /clang/unittests | |
| parent | 5c65e7f345967189ca98f9ed88787d5487c77bb3 (diff) | |
| download | bcm5719-llvm-559b63cbb94e7027fe73df929d63703a1a3bc0c9.tar.gz bcm5719-llvm-559b63cbb94e7027fe73df929d63703a1a3bc0c9.zip | |
clang-format: Understand __attribute__s preceding parameter lists.
Before:
ReturnType __attribute__((unused))
function(int i);
After:
ReturnType __attribute__((unused))
function(int i);
This fixes llvm.org/PR18632.
llvm-svn: 200337
Diffstat (limited to 'clang/unittests')
| -rw-r--r-- | clang/unittests/Format/FormatTest.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp index 1a197545754..efc563b4f25 100644 --- a/clang/unittests/Format/FormatTest.cpp +++ b/clang/unittests/Format/FormatTest.cpp @@ -4394,6 +4394,8 @@ TEST_F(FormatTest, UnderstandsUsesOfStarAndAmp) { TEST_F(FormatTest, UnderstandsAttributes) { verifyFormat("SomeType s __attribute__((unused)) (InitValue);"); + verifyFormat("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa __attribute__((unused))\n" + "aaaaaaaaaaaaaaaaaaaaaaa(int i);"); } TEST_F(FormatTest, UnderstandsEllipsis) { |

