diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2009-05-15 21:18:04 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2009-05-15 21:18:04 +0000 |
commit | 6802ed99684f42e0e5eb604e33f51e5d5e616f8f (patch) | |
tree | dd0700224c7fa1a2ac3445daa4fec8fbb53e450a /clang/test/Sema/block-sentinel-attribute.c | |
parent | eef7a21507e58c7074d72a7d87e5e0bc772d03fe (diff) | |
download | bcm5719-llvm-6802ed99684f42e0e5eb604e33f51e5d5e616f8f.tar.gz bcm5719-llvm-6802ed99684f42e0e5eb604e33f51e5d5e616f8f.zip |
improved on diagnosing misplacement of sentinel attributes.
No change in functionality.
llvm-svn: 71894
Diffstat (limited to 'clang/test/Sema/block-sentinel-attribute.c')
-rw-r--r-- | clang/test/Sema/block-sentinel-attribute.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/test/Sema/block-sentinel-attribute.c b/clang/test/Sema/block-sentinel-attribute.c index c78f526cdf7..a7d4df108ea 100644 --- a/clang/test/Sema/block-sentinel-attribute.c +++ b/clang/test/Sema/block-sentinel-attribute.c @@ -4,6 +4,7 @@ void (^e) (int arg, const char * format, ...) __attribute__ ((__sentinel__ (1,1) int main() { + void (^bbad) (int arg, const char * format) __attribute__ ((__sentinel__)) ; // expected-warning {{sentinel' attribute only supported for variadic blocks}} void (^b) (int arg, const char * format, ...) __attribute__ ((__sentinel__)) = // expected-note {{block has been explicitly marked sentinel here}} ^ __attribute__ ((__sentinel__)) (int arg, const char * format, ...) {}; void (^z) (int arg, const char * format, ...) __attribute__ ((__sentinel__ (2))) = ^ __attribute__ ((__sentinel__ (2))) (int arg, const char * format, ...) {}; // expected-note {{block has been explicitly marked sentinel here}} |