summaryrefslogtreecommitdiff
path: root/test/SemaObjC/return.m
diff options
context:
space:
mode:
Diffstat (limited to 'test/SemaObjC/return.m')
-rw-r--r--test/SemaObjC/return.m11
1 files changed, 10 insertions, 1 deletions
diff --git a/test/SemaObjC/return.m b/test/SemaObjC/return.m
index 3a626e3696035..4e70bde1edc14 100644
--- a/test/SemaObjC/return.m
+++ b/test/SemaObjC/return.m
@@ -14,7 +14,7 @@ void test2(int a) {
}
// PR5286
-void test3(int a) { // expected-warning {{function could be attribute 'noreturn'}}
+void test3(int a) { // expected-warning {{function 'test3' could be declared with attribute 'noreturn'}}
while (1) {
if (a)
@throw (id)0;
@@ -39,3 +39,12 @@ NSString *rdar_4289832() { // no-warning
}
}
+void exit(int) __attribute__((noreturn));
+@interface rdar10098695
+@end
+
+@implementation rdar10098695
+- (void)method { // expected-warning{{method 'method' could be declared with attribute 'noreturn'}}
+ exit(1);
+}
+@end