diff options
author | Nico Weber <nicolasweber@gmx.de> | 2013-01-10 00:42:07 +0000 |
---|---|---|
committer | Nico Weber <nicolasweber@gmx.de> | 2013-01-10 00:42:07 +0000 |
commit | bbe28b3d809299e9c590dc69f3f00cdea417fc91 (patch) | |
tree | 3e77e19786f8764d873901567df805bd1218bcd8 | |
parent | 51306d232edd03db956ba4007bea691ba5ceca20 (diff) | |
download | bcm5719-llvm-bbe28b3d809299e9c590dc69f3f00cdea417fc91.tar.gz bcm5719-llvm-bbe28b3d809299e9c590dc69f3f00cdea417fc91.zip |
Formatter: Remove unused @-formatting code.
@optional @property is put on two different unwrapped lines now, so this is no
longer necessary.
llvm-svn: 172024
-rw-r--r-- | clang/lib/Format/Format.cpp | 4 | ||||
-rw-r--r-- | clang/unittests/Format/FormatTest.cpp | 2 |
2 files changed, 2 insertions, 4 deletions
diff --git a/clang/lib/Format/Format.cpp b/clang/lib/Format/Format.cpp index beea48e9a3f..1ab577049c6 100644 --- a/clang/lib/Format/Format.cpp +++ b/clang/lib/Format/Format.cpp @@ -812,10 +812,6 @@ public: TT_LineComment || (Current.is(tok::string_literal) && Current.Parent->is(tok::string_literal))) { Current.MustBreakBefore = true; - } else if (Current.is(tok::at) && Current.Parent->Parent->is(tok::at)) { - // Don't put two objc's '@' on the same line. This could happen, - // as in, @optional @property ... - Current.MustBreakBefore = true; } else { Current.MustBreakBefore = false; } diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp index 9ed6b5f0f9a..389c58c4288 100644 --- a/clang/unittests/Format/FormatTest.cpp +++ b/clang/unittests/Format/FormatTest.cpp @@ -1347,6 +1347,8 @@ TEST_F(FormatTest, FormatObjCProtocol) { "- (void)optional;\n" "@required\n" "- (void)required;\n" + "@optional\n" + "@property(assign) int madProp;\n" "@end\n"); } |