diff options
author | Daniel Jasper <djasper@google.com> | 2015-12-28 07:44:25 +0000 |
---|---|---|
committer | Daniel Jasper <djasper@google.com> | 2015-12-28 07:44:25 +0000 |
commit | a85c331e8f9c5f63fa37c2334e3ea40423c20d8a (patch) | |
tree | 482a553a4dded751bd66e07f749822105870fc1d /clang/unittests/Format/FormatTest.cpp | |
parent | 6402bcad714d776a9ee2e6d427e0dfb363915032 (diff) | |
download | bcm5719-llvm-a85c331e8f9c5f63fa37c2334e3ea40423c20d8a.tar.gz bcm5719-llvm-a85c331e8f9c5f63fa37c2334e3ea40423c20d8a.zip |
clang-format: Fix incorrect function type detection.
Before:
int x = f (&h)();
After:
int x = f(&h)();
llvm-svn: 256488
Diffstat (limited to 'clang/unittests/Format/FormatTest.cpp')
-rw-r--r-- | clang/unittests/Format/FormatTest.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp index 9d7521fee10..6a0506d8973 100644 --- a/clang/unittests/Format/FormatTest.cpp +++ b/clang/unittests/Format/FormatTest.cpp @@ -5928,6 +5928,7 @@ TEST_F(FormatTest, FormatsFunctionTypes) { verifyFormat("#define DEREF_AND_CALL_F(x) f(*x)"); verifyFormat("some_var = function(*some_pointer_var)[0];"); verifyFormat("void f() { function(*some_pointer_var)[0] = 10; }"); + verifyFormat("int x = f(&h)();"); } TEST_F(FormatTest, FormatsPointersToArrayTypes) { |