https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101869
--- Comment #8 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-11 branch has been updated by Jason Merrill <ja...@gcc.gnu.org>: https://gcc.gnu.org/g:691e385b354482f3379bba471774873ca7179b79 commit r11-10643-g691e385b354482f3379bba471774873ca7179b79 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.