1// { dg-do assemble } 2// g++ 1.37.1 bug 900407_01 3 4// g++ fails to flag errors for uses of anachronistic features such as the 5// invocation of a base class constructor in a ctor-initializer list without 6// explicitly giving its name. 7 8// Errors should probably be issued for such usage unless the -traditional 9// option is used. 10 11// Warnings are however issued. 12 13// Cfront 2.0 flags such usage as an error when the +p (pure-language) option 14// is used. 15 16// Cfront 2.0 passes this test. 17 18// keywords: anachronism, inheritance, initialization, mem-initializer 19 20struct s0 { 21 int member; 22 23 s0 (); 24}; 25 26s0::s0() { } 27 28struct s1 : public s0 { 29 int member; 30 31 s1 (); 32}; 33 34s1::s1() : () { // { dg-error "" } anachronism used 35} 36 37int main () { return 0; } 38