summaryrefslogtreecommitdiffstats
path: root/test/Index/comment-objc-decls.m
diff options
context:
space:
mode:
authorFariborz Jahanian <fjahanian@apple.com>2012-12-20 19:54:13 +0000
committerFariborz Jahanian <fjahanian@apple.com>2012-12-20 19:54:13 +0000
commit154120cde4f56ed04261bab302fdbbed1a7f080b (patch)
tree52ef97dca08e390c8bb4574e655d145146f7b502 /test/Index/comment-objc-decls.m
parentbbf4d53343c2bbd082b7c1488f34650a7d07ae3b (diff)
Add objective-C style formatting to clang format and
use it to format xml declaration tags. // rdar://12378714 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@170727 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Index/comment-objc-decls.m')
-rw-r--r--test/Index/comment-objc-decls.m36
1 files changed, 18 insertions, 18 deletions
diff --git a/test/Index/comment-objc-decls.m b/test/Index/comment-objc-decls.m
index d037e05db2..6682ea320f 100644
--- a/test/Index/comment-objc-decls.m
+++ b/test/Index/comment-objc-decls.m
@@ -31,9 +31,9 @@
+ ClassMethodMyProto;
@end
// CHECK: <Declaration>@protocol MyProto\n@end</Declaration>
-// CHECK: <Declaration>- (unsigned int) MethodMyProto:(id)anObject inRange:(unsigned int)range;</Declaration>
-// CHECK: <Declaration>@optional\n@property ( readwrite,copy,atomic ) id PropertyMyProto;</Declaration>
-// CHECK: <Declaration>+ (id) ClassMethodMyProto;</Declaration>
+// CHECK: <Declaration>- (unsigned int)MethodMyProto:(id)anObject inRange:(unsigned int)range;</Declaration>
+// CHECK: <Declaration>@optional\n @property(readwrite, copy, atomic) id PropertyMyProto;</Declaration>
+// CHECK: <Declaration>+ (id)ClassMethodMyProto;</Declaration>
/**
* \brief NSObject is the root class.
@@ -45,7 +45,7 @@
id IvarNSObject;
}
@end
-// CHECK: Declaration>@interface NSObject{\n id IvarNSObject;\n}\n@end</Declaration>
+// CHECK: Declaration>@interface NSObject {\n id IvarNSObject;\n}\n@end</Declaration>
// CHECK: <Declaration>id IvarNSObject</Declaration>
/**
@@ -75,9 +75,9 @@
@end
// CHECK: <Declaration>@interface MyClass : NSObject&lt;MyProto&gt; {\n id IvarMyClass;\n}\n@end</Declaration>
// CHECK: <Declaration>id IvarMyClass</Declaration>
-// CHECK: <Declaration>- (id) MethodMyClass;</Declaration>
-// CHECK: <Declaration>+ (id) ClassMethodMyClass;</Declaration>
-// CHECK: <Declaration>@property ( readwrite,copy,atomic ) id PropertyMyClass;</Declaration
+// CHECK: <Declaration>- (id)MethodMyClass;</Declaration>
+// CHECK: <Declaration>+ (id)ClassMethodMyClass;</Declaration>
+// CHECK: <Declaration>@property(readwrite, copy, atomic) id PropertyMyClass;</Declaration
/**
* \brief - This is class extension of MyClass
@@ -90,7 +90,7 @@
id IvarMyClassExtension;
}
@end
-// CHECK: <Declaration>@interface MyClass()\n{\n id IvarMyClassExtension;\n}\n@end</Declaration>
+// CHECK: <Declaration>@interface MyClass() {\n id IvarMyClassExtension;\n}\n@end</Declaration>
// CHECK: <Declaration>id IvarMyClassExtension</Declaration>
@@ -109,10 +109,10 @@
@property (copy) id PropertyMyClassCategory;
@end
// CHECK: <Declaration>@interface MyClass(Category)\n@end</Declaration>
-// CHECK: <Declaration>- (void) MethodMyClassCategory;</Declaration>
-// CHECK: <Declaration>@property ( readwrite,copy,atomic ) id PropertyMyClassCategory;</Declaration>
-// CHECK: <Declaration>- (id) PropertyMyClassCategory;</Declaration>
-// CHECK: <Declaration>- (void) setPropertyMyClassCategory:(id)arg;</Declaration>
+// CHECK: <Declaration>- (void)MethodMyClassCategory;</Declaration>
+// CHECK: <Declaration>@property(readwrite, copy, atomic) id PropertyMyClassCategory;</Declaration>
+// CHECK: <Declaration>- (id)PropertyMyClassCategory;</Declaration>
+// CHECK: <Declaration>- (void)setPropertyMyClassCategory:(id)arg;</Declaration>
/// @implementation's
@@ -139,10 +139,10 @@
return 0;
}
@end
-// CHECK: <Declaration>@implementation MyClass{\n id IvarPrivateToMyClassImpl;\n id _PropertyMyClass;\n}\n@end</Declaration>
+// CHECK: <Declaration>@implementation MyClass {\n id IvarPrivateToMyClassImpl;\n id _PropertyMyClass;\n}\n@end</Declaration>
// CHECK: <Declaration>id IvarPrivateToMyClassImpl</Declaration>
-// CHECK: <Declaration>- (id) MethodMyClass;</Declaration>
-// CHECK: <Declaration>+ (id) ClassMethodMyClass;</Declaration>
+// CHECK: <Declaration>- (id)MethodMyClass;</Declaration>
+// CHECK: <Declaration>+ (id)ClassMethodMyClass;</Declaration>
/**
* \brief MyClass (Category) is implementation of private to MyClass.
@@ -163,9 +163,9 @@
- (void) setPropertyMyClassCategory : (id) arg {}
@end
// CHECK: <Declaration>@implementation MyClass(Category)\n@end</Declaration>
-// CHECK: <Declaration>- (void) MethodMyClassCategory;</Declaration>
-// CHECK: <Declaration>- (id) PropertyMyClassCategory;</Declaration>
-// CHECK: <Declaration>- (void) setPropertyMyClassCategory:(id)arg;</Declaration>
+// CHECK: <Declaration>- (void)MethodMyClassCategory;</Declaration>
+// CHECK: <Declaration>- (id)PropertyMyClassCategory;</Declaration>
+// CHECK: <Declaration>- (void)setPropertyMyClassCategory:(id)arg;</Declaration>
/**
* \brief NSObject implementation