diff options
author | Daniel Jasper <djasper@google.com> | 2013-03-22 16:55:40 +0000 |
---|---|---|
committer | Daniel Jasper <djasper@google.com> | 2013-03-22 16:55:40 +0000 |
commit | 627707b9360597b65a9a0953d0ead2a08c3a0d5d (patch) | |
tree | a274b38e07d52c0e3b5fbeb7a58f8283e05ee2bb /unittests/Format/FormatTest.cpp | |
parent | c363dbb204b6c77b67dfed030436643947b37cbd (diff) |
Better fix for r177725.
It turns out that
-foo;
can be an objective C method declaration. So instead of the previous
solution, recognize objective C methods only if we are in a declaration
scope.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@177740 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests/Format/FormatTest.cpp')
-rw-r--r-- | unittests/Format/FormatTest.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/unittests/Format/FormatTest.cpp b/unittests/Format/FormatTest.cpp index 0840302754..5988a90596 100644 --- a/unittests/Format/FormatTest.cpp +++ b/unittests/Format/FormatTest.cpp @@ -2815,6 +2815,7 @@ TEST_F(FormatTest, FormatForObjectiveCMethodDecls) { // If there's no return type (very rare in practice!), LLVM and Google style // agree. + verifyFormat("- foo;"); verifyFormat("- foo:(int)f;"); verifyGoogleFormat("- foo:(int)foo;"); } |