aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/Format/Format.cpp4
-rw-r--r--unittests/Format/FormatTest.cpp2
2 files changed, 2 insertions, 4 deletions
diff --git a/lib/Format/Format.cpp b/lib/Format/Format.cpp
index beea48e9a3..1ab577049c 100644
--- a/lib/Format/Format.cpp
+++ b/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/unittests/Format/FormatTest.cpp b/unittests/Format/FormatTest.cpp
index 9ed6b5f0f9..389c58c428 100644
--- a/unittests/Format/FormatTest.cpp
+++ b/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");
}