FSF GCC merge 02/23/03
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.bugs / 900511_02.C
blobcef71c0a12e2e6c5714847963725f6a24d81b869
1 // g++ 1.37.1 bug 900511_02
3 // g++ does not properly shadow names of types with names of data members
4 // in cases where the type names in question are used in the context of
5 // formal parameters lists for member functions.
7 // keywords: typedef names, shadowing, scope, formal parameter list
9 // cfront 2.0 passes this test.
11 enum enum0 { enum0_value_0 };   
13 struct struct0 {
14   int enum0;                    
15   void member_function (enum0 e); // ERROR - invalid use of struct-local member
18 void class0::member_function (enum0 e) {        // ERROR - syntax error
21 int main () { return 0; }