https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116606
--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-13 branch has been updated by Jakub Jelinek <ja...@gcc.gnu.org>: https://gcc.gnu.org/g:d0f2b0711f24238c5daefc97448d2f1b3a856359 commit r13-9690-gd0f2b0711f24238c5daefc97448d2f1b3a856359 Author: Marek Polacek <pola...@redhat.com> Date: Thu Sep 5 13:01:59 2024 -0400 c++: vtable referring to "unavailable" virtual fn [PR116606] mark_vtable_entries already has /* It's OK for the vtable to refer to deprecated virtual functions. */ warning_sentinel w(warn_deprecated_decl); but that doesn't cover __attribute__((unavailable)). We can use the following override to cover both. PR c++/116606 gcc/cp/ChangeLog: * decl2.cc (mark_vtable_entries): Temporarily override deprecated_state to UNAVAILABLE_DEPRECATED_SUPPRESS. Remove a warning_sentinel. gcc/testsuite/ChangeLog: * g++.dg/ext/attr-unavailable-13.C: New test. (cherry picked from commit d9d34f9a91371dea4bab0b54b2d7f762a6cc23e0)