aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.old-deja/g++.bugs/900404_04.C
blob: 04ff66905498c3dedc2cff1f6aab23afbb4234bd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// { dg-do assemble  }
// g++ 1.37.1 bug 900404_04

// [dcl.dcl] explains that simple-declarations may omit the
// init-declarator-list only if the decl-specifier-seq declares a
// class, i.e. if it contains a class-specifier, an
// elaborated-type-specifier with class key, or an enum-specifier. The
// declaration below contains neither.

// g++ fails to flag errors for such usage.

// keywords: semicolon, vacuous, file scope, declaration

int i;

;			// { dg-error "extra ';'" } 

int main () { return 0; }