diff options
author | Peter Collingbourne <peter@pcc.me.uk> | 2011-07-27 20:30:05 +0000 |
---|---|---|
committer | Peter Collingbourne <peter@pcc.me.uk> | 2011-07-27 20:30:05 +0000 |
commit | 8f5f520653f5dcbaf0a5673fcb3497ec9cb25dad (patch) | |
tree | 269851dd3c636a3c6c2c65c24d6362d36eaa69da /clang/test/Sema/address_spaces.c | |
parent | 78769e691ae2507fd594f93d82a2d9945fd1b364 (diff) | |
download | bcm5719-llvm-8f5f520653f5dcbaf0a5673fcb3497ec9cb25dad.tar.gz bcm5719-llvm-8f5f520653f5dcbaf0a5673fcb3497ec9cb25dad.zip |
Forbid address-space-qualified function types, per TR 18037
llvm-svn: 136257
Diffstat (limited to 'clang/test/Sema/address_spaces.c')
-rw-r--r-- | clang/test/Sema/address_spaces.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/test/Sema/address_spaces.c b/clang/test/Sema/address_spaces.c index a53bb4da000..24799daa9e5 100644 --- a/clang/test/Sema/address_spaces.c +++ b/clang/test/Sema/address_spaces.c @@ -44,3 +44,7 @@ void test3(void) { extern void test3_helper(char *p); // expected-note {{passing argument to parameter 'p' here}} test3_helper(test3_array); // expected-error {{changes address space of pointer}} } + +typedef void ft(void); +_AS1 ft qf; // expected-error {{function type may not be qualified with an address space}} +typedef _AS1 ft qft; // expected-error {{function type may not be qualified with an address space}} |