2008-02-11 02:08:00 +03:00
|
|
|
// RUN: clang %s -fsyntax-only -verify -pedantic
|
2007-07-11 21:01:13 +04:00
|
|
|
|
|
|
|
extern int a1[];
|
|
|
|
|
|
|
|
void f0();
|
|
|
|
void f1(int [*]);
|
|
|
|
void f2(int [const *]);
|
|
|
|
void f3(int [volatile const*]);
|
2008-04-05 10:32:51 +04:00
|
|
|
int f4(*XX)(void); /* expected-error {{cannot return}} expected-warning {{type specifier missing, defaults to 'int'}} */
|
2007-07-11 21:01:13 +04:00
|
|
|
|
|
|
|
char ((((*X))));
|
|
|
|
|
|
|
|
void (*signal(int, void (*)(int)))(int);
|
|
|
|
|
|
|
|
int a, ***C, * const D, b(int);
|
|
|
|
|
|
|
|
int *A;
|
|
|
|
|
|
|
|
struct str;
|
|
|
|
|
|
|
|
int test2(int *P, int A) {
|
|
|
|
struct str;
|
|
|
|
|
|
|
|
// Hard case for array decl, not Array[*].
|
|
|
|
int Array[*(int*)P+A];
|
|
|
|
}
|
|
|
|
|
2008-04-06 10:47:48 +04:00
|
|
|
typedef int atype;
|
|
|
|
int test3(x,
|
|
|
|
atype /* expected-error {{unexpected type name 'atype': expected identifier}} */
|
|
|
|
) int x, atype; {}
|
2007-07-11 21:01:13 +04:00
|
|
|
|