diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/Sema/function-redecl.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/Sema/function-redecl.c b/test/Sema/function-redecl.c index 80500664af..fc2e1995f2 100644 --- a/test/Sema/function-redecl.c +++ b/test/Sema/function-redecl.c @@ -116,3 +116,12 @@ extern __typeof (h1) h1 __attribute__((__sentinel__)); void i0 (unsigned short a0); extern __typeof (i0) i1; extern __typeof (i1) i1; + +typedef int a(); +typedef int a2(int*); +a x; +a2 x2; +void test_x() { + x(5); + x2(5); // expected-warning{{incompatible integer to pointer conversion passing 'int', expected 'int *'}} +} |