diff options
author | Daniel Jasper <djasper@google.com> | 2014-11-10 16:57:30 +0000 |
---|---|---|
committer | Daniel Jasper <djasper@google.com> | 2014-11-10 16:57:30 +0000 |
commit | 2b03c6434c91542ebc969fa2e57fbd802177d890 (patch) | |
tree | d14292e3adafe000c66d16e73165042bdf77a8dd /unittests | |
parent | ae1c3ef1cf20df7c8d7828364d5f0412042604e8 (diff) |
clang-format: Fix pointer formatting.
Before:
void f(Bar* a = nullptr, Bar * b);
After:
void f(Bar* a = nullptr, Bar* b);
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@221609 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests')
-rw-r--r-- | unittests/Format/FormatTest.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/unittests/Format/FormatTest.cpp b/unittests/Format/FormatTest.cpp index 9d62fbe14f..3485392d4f 100644 --- a/unittests/Format/FormatTest.cpp +++ b/unittests/Format/FormatTest.cpp @@ -4984,6 +4984,9 @@ TEST_F(FormatTest, UnderstandsUsesOfStarAndAmp) { verifyGoogleFormat( "const char* const p = reinterpret_cast<const char* const>(q);"); verifyGoogleFormat("void f(int i = 0, SomeType** temps = NULL);"); + verifyGoogleFormat("void f(Bar* a = nullptr, Bar* b);"); + verifyGoogleFormat("template <typename T>\n" + "void f(int i = 0, SomeType** temps = NULL);"); FormatStyle Left = getLLVMStyle(); Left.PointerAlignment = FormatStyle::PAS_Left; |