struct foo_bar; typedef foo_bar bar;
struct foo_bar { typedef int baz; bar::baz ii; }; t.C:7: error: baz in class bar does not name a type or as originally reported: struct foo_bar; namespace foo { typedef foo_bar bar; }; struct foo_bar { typedef int baz; foo::bar::baz ii; }; t.C:9: error: baz in class foo::bar does not name a type moving the declaration of ii out of foo_bar, the code is accepted: struct foo_bar; typedef foo_bar bar; struct foo_bar { typedef int baz; }; bar::baz ii; EDG happily accepts the code in strict-ansi mode. -- Summary: [4.0/4.1/4.2/4.3 Regression] Rejects typedef qualified name-lookup Product: gcc Version: 4.3.0 Status: UNCONFIRMED Keywords: rejects-valid Severity: normal Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: rguenth at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33516