diff options
Diffstat (limited to 'clang/test')
-rw-r--r-- | clang/test/Sema/overloadable.c | 1 | ||||
-rw-r--r-- | clang/test/SemaObjC/nsobject-attribute.m | 2 |
2 files changed, 3 insertions, 0 deletions
diff --git a/clang/test/Sema/overloadable.c b/clang/test/Sema/overloadable.c index ad021898f2a..076e05e91a2 100644 --- a/clang/test/Sema/overloadable.c +++ b/clang/test/Sema/overloadable.c @@ -1,6 +1,7 @@ // RUN: %clang_cc1 -fsyntax-only -verify %s int var __attribute__((overloadable)); // expected-error{{'overloadable' attribute can only be applied to a function}} +void params(void) __attribute__((overloadable(12))); // expected-error {{attribute takes no arguments}} int *f(int) __attribute__((overloadable)); // expected-note 2{{previous overload of function is here}} float *f(float); // expected-error{{overloaded function 'f' must have the 'overloadable' attribute}} diff --git a/clang/test/SemaObjC/nsobject-attribute.m b/clang/test/SemaObjC/nsobject-attribute.m index b794eafc9ed..64fa83884a5 100644 --- a/clang/test/SemaObjC/nsobject-attribute.m +++ b/clang/test/SemaObjC/nsobject-attribute.m @@ -1,6 +1,8 @@ // RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s typedef struct CGColor * __attribute__ ((NSObject)) CGColorRef; +typedef struct CGColor * __attribute__((NSObject(12))) Illegal; // expected-error {{attribute takes no arguments}} + static int count; static CGColorRef tmp = 0; |