https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92890
Bug ID: 92890 Summary: Member name lookup Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: nknikita at niisi dot ras.ru Target Milestone: --- An example from ISO/IEC 14882:2017 (E) [class.member.lookup]/7: struct A { int x; }; // S(x,A) = {{A::x},{A}} struct B { float x; }; // S(x,B) = {{B::x},{B}} struct C: public A, public B {}; // S(x,C) = {{invalid}, {A in C, B in C}} struct D: public virtual C {}; // S(x,D) = S(x,C) struct E: public virtual C { char x; }; // S(x,E) = {{E::x},{E}} struct F: public D, public E {}; // S(x,F) = S(x,E) int main () { F f; f.x = 0; // OK, lookup finds E::x } g++ is unable to compile it. I don't know if this error or not, but the example can be compiled with clang++ (> 3.8.0) and vc++. The example is still present in N4842.