]> granicus.if.org Git - clang/commitdiff
Slightly expand the @ test to cover whitespace between @ and keyword.
authorNico Weber <nicolasweber@gmx.de>
Mon, 7 Jan 2013 15:56:25 +0000 (15:56 +0000)
committerNico Weber <nicolasweber@gmx.de>
Mon, 7 Jan 2013 15:56:25 +0000 (15:56 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@171751 91177308-0d34-0410-b5e6-96231b3b80d8

unittests/Format/FormatTest.cpp

index 3a67e2dfa18a16dc5cad3ffdaf88785491b3b2ac..3c056cd994e1a2aa477df760cb6c9bc27cf22513 100644 (file)
@@ -1021,9 +1021,14 @@ TEST_F(FormatTest, FormatForObjectiveCMethodDecls) {
           "outRange8:(NSRange) out_range8  outRange9:(NSRange) out_range9;"));
 }
 
-TEST_F(FormatTest, DoNotDropAt) {
+TEST_F(FormatTest, ObjCAt) {
   verifyFormat("@interface");
   verifyFormat("@dynamic");
+  EXPECT_EQ("@interface", format("@ interface"));
+
+  // The precise formatting of this doesn't matter, nobody writes code like
+  // this.
+  verifyFormat("@ /*foo*/ interface");
 }
 
 } // end namespace tooling