diff options
author | Steve Naroff <snaroff@apple.com> | 2009-03-03 20:59:06 +0000 |
---|---|---|
committer | Steve Naroff <snaroff@apple.com> | 2009-03-03 20:59:06 +0000 |
commit | 39d6fba0d630a4895a7e227b5ea52992cbcd13b3 (patch) | |
tree | b7756efcc8b382f8f551f71a1b77f696fdd0eebe /clang/test/SemaObjC/catch-stmt.m | |
parent | 7956bba54578f83ab666d8d7087d44e6692a39d5 (diff) | |
download | bcm5719-llvm-39d6fba0d630a4895a7e227b5ea52992cbcd13b3.tar.gz bcm5719-llvm-39d6fba0d630a4895a7e227b5ea52992cbcd13b3.zip |
Fix <rdar://problem/6632061> [sema] non object types should not be allowed in @catch statements.
llvm-svn: 65968
Diffstat (limited to 'clang/test/SemaObjC/catch-stmt.m')
-rw-r--r-- | clang/test/SemaObjC/catch-stmt.m | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/clang/test/SemaObjC/catch-stmt.m b/clang/test/SemaObjC/catch-stmt.m new file mode 100644 index 00000000000..9aa6e057f4f --- /dev/null +++ b/clang/test/SemaObjC/catch-stmt.m @@ -0,0 +1,10 @@ +// RUN: clang -verify %s + +void f() { + @try { + } @catch (void a) { // expected-error{{@catch parameter is not an Objective-C class type}} + } @catch (int) { // expected-error{{@catch parameter is not an Objective-C class type}} + } @catch (int *b) { // expected-error{{@catch parameter is not an Objective-C class type}} + } +} + |