summaryrefslogtreecommitdiffstats
path: root/test/Parser/method-def-in-class.m
diff options
context:
space:
mode:
Diffstat (limited to 'test/Parser/method-def-in-class.m')
-rw-r--r--test/Parser/method-def-in-class.m25
1 files changed, 25 insertions, 0 deletions
diff --git a/test/Parser/method-def-in-class.m b/test/Parser/method-def-in-class.m
new file mode 100644
index 0000000..490c055
--- /dev/null
+++ b/test/Parser/method-def-in-class.m
@@ -0,0 +1,25 @@
+// RUN: %clang_cc1 -fsyntax-only -verify %s
+// rdar://7029784
+
+@interface A
+-(id) f0 { // expected-error {{expected ';' after method prototype}}
+ assert(0);
+}
+@end
+
+@interface B
+-(id) f0 { // expected-error {{expected ';' after method prototype}}
+ assert(0);
+@end
+
+@interface C
+- (id) f0 { // expected-error {{expected ';' after method prototype}}
+ assert(0);
+};
+@end
+
+@interface D
+- (id) f0 { // expected-error {{expected ';' after method prototype}}
+ assert(0);
+@property int P;
+@end
OpenPOWER on IntegriCloud