| 1 |
// { dg-do assemble } |
| 2 |
// g++ 1.37.1 bug 900511_02 |
| 3 |
|
| 4 |
// g++ does not properly shadow names of types with names of data members |
| 5 |
// in cases where the type names in question are used in the context of |
| 6 |
// formal parameters lists for member functions. |
| 7 |
|
| 8 |
// keywords: typedef names, shadowing, scope, formal parameter list |
| 9 |
|
| 10 |
// cfront 2.0 passes this test. |
| 11 |
|
| 12 |
enum enum0 { enum0_value_0 }; |
| 13 |
|
| 14 |
struct struct0 { |
| 15 |
int enum0; |
| 16 |
void member_function (enum0 e); // { dg-error "" } invalid use of struct-local member |
| 17 |
}; |
| 18 |
|
| 19 |
void class0::member_function (enum0 e) { // { dg-error "" } syntax error |
| 20 |
} |
| 21 |
|
| 22 |
int main () { return 0; } |