]> git.ipfire.org Git - thirdparty/gcc.git/commit
c++: &enum::enumerator [PR101869]
authorJason Merrill <jason@redhat.com>
Thu, 16 Mar 2023 17:11:32 +0000 (13:11 -0400)
committerJason Merrill <jason@redhat.com>
Tue, 18 Apr 2023 20:44:27 +0000 (16:44 -0400)
commit2f9bb63c5e82512ba9e53f4d5e67949c100d8830
tree141c3b028339a7271bb9fae2ce12cb9f3b618b33
parent6fd32842404ac1a3cd98189f61d93c5bc9c8680c
c++: &enum::enumerator [PR101869]

We don't want to call build_offset_ref with an enum.

PR c++/101869

gcc/cp/ChangeLog:

* semantics.cc (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.
gcc/cp/semantics.cc
gcc/testsuite/g++.dg/cpp0x/enum43.C [new file with mode: 0644]