https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101869
--- Comment #7 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-10 branch has been updated by Jason Merrill <ja...@gcc.gnu.org>: https://gcc.gnu.org/g:6f7f90113bc78440a248bef4b917583fde3e6e5f commit r10-11303-g6f7f90113bc78440a248bef4b917583fde3e6e5f Author: Jason Merrill <ja...@redhat.com> Date: Thu Mar 16 13:11:32 2023 -0400 c++: &enum::enumerator [PR101869] We don't want to call build_offset_ref with an enum. PR c++/101869 gcc/cp/ChangeLog: * semantics.c (finish_qualified_id_expr): Don't try to build a pointer-to-member if the scope is an enumeration. gcc/testsuite/ChangeLog: * g++.dg/cpp0x/enum43.C: New test.