summaryrefslogtreecommitdiffstats
path: root/test/Sema/alloc_size.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/Sema/alloc_size.c')
-rw-r--r--test/Sema/alloc_size.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/Sema/alloc_size.c b/test/Sema/alloc_size.c
index 84f3932..053323a 100644
--- a/test/Sema/alloc_size.c
+++ b/test/Sema/alloc_size.c
@@ -5,9 +5,9 @@ void* my_calloc(unsigned char, short) __attribute__((alloc_size(1,2)));
void* my_realloc(void*, unsigned) __attribute__((alloc_size(2)));
-void* fn1(int) __attribute__((alloc_size("xpto"))); // expected-error{{attribute requires integer constant}}
+void* fn1(int) __attribute__((alloc_size("xpto"))); // expected-error{{'alloc_size' attribute requires parameter 1 to be an integer constant}}
-void* fn2(void*) __attribute__((alloc_size(1))); // expected-error{{attribute requires integer constant}}
+void* fn2(void*) __attribute__((alloc_size(1))); // expected-error{{'alloc_size' attribute requires an integer constant}}
void* fn3(unsigned) __attribute__((alloc_size(0))); // expected-error{{attribute parameter 1 is out of bounds}}
void* fn4(unsigned) __attribute__((alloc_size(2))); // expected-error{{attribute parameter 1 is out of bounds}}
@@ -19,7 +19,7 @@ void* fn7(unsigned) __attribute__((alloc_size)); // expected-error {{attribute t
void *fn8(int, int) __attribute__((alloc_size(1, 1))); // OK
-void* fn9(unsigned) __attribute__((alloc_size(12345678901234567890123))); // expected-warning {{integer constant is too large for its type}} // expected-error {{attribute parameter 1 is out of bounds}}
+void* fn9(unsigned) __attribute__((alloc_size(12345678901234567890123))); // expected-error {{integer constant is larger than the largest unsigned integer type}} // expected-error {{attribute parameter 1 is out of bounds}}
void* fn10(size_t, size_t) __attribute__((alloc_size(1,2))); // expected-error{{redefinition of parameter}} \
// expected-error{{a parameter list without types is only allowed in a function definition}} \
OpenPOWER on IntegriCloud