summaryrefslogtreecommitdiffstats
path: root/clang/test/Sema/format-attribute.c
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2008-05-09 17:36:24 +0000
committerTed Kremenek <kremenek@apple.com>2008-05-09 17:36:24 +0000
commit712c91f8a9cd5a10afba9081f3a71c281a4238e5 (patch)
treef2efbbd21ed43a5092ec6eb36058fc21cb3eeec3 /clang/test/Sema/format-attribute.c
parentbbd4695a45f1d8550c0516136658d4af1f934beb (diff)
downloadbcm5719-llvm-712c91f8a9cd5a10afba9081f3a71c281a4238e5.tar.gz
bcm5719-llvm-712c91f8a9cd5a10afba9081f3a71c281a4238e5.zip
Add attribute "format" support for typedefs of function pointers.
llvm-svn: 50906
Diffstat (limited to 'clang/test/Sema/format-attribute.c')
-rw-r--r--clang/test/Sema/format-attribute.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/test/Sema/format-attribute.c b/clang/test/Sema/format-attribute.c
index 8eefe3f0654..ecdef9dde1a 100644
--- a/clang/test/Sema/format-attribute.c
+++ b/clang/test/Sema/format-attribute.c
@@ -22,3 +22,5 @@ struct _mystruct {
int (*printf)(const char *format, ...) __attribute__((__format__(printf, 1, 2))); // no-error
int (*printf2)(double format, ...) __attribute__((__format__(printf, 1, 2))); // expected-error {{format argument not a string type}}
};
+
+typedef int (*f3_ptr)(char*,...) __attribute__((format(printf,1,0))); // no-error
OpenPOWER on IntegriCloud