https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119064
--- Comment #10 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Jakub Jelinek <[email protected]>: https://gcc.gnu.org/g:bbd96065fa7e256d03c892d10813cfa4b3e609a8 commit r16-5114-gbbd96065fa7e256d03c892d10813cfa4b3e609a8 Author: Jakub Jelinek <[email protected]> Date: Mon Nov 10 12:52:45 2025 +0100 c++: Implement C++26 P3920R0 - Wording for NB comment resolution on trivial relocation Trivial relocation was voted out of C++26, the following patch removes it (note, the libstdc++ part was still waiting for patch review and so doesn't need to be removed). This isn't a mere revert of r16-2206; I've kept -Wc++26-compat option, from earlier patches the non-terminal stays to be class-property-specifier, and I had to partially revert also various follow-up changes, e.g. for modules to handle the new flags and test them, for -Wkeyword-macro etc. to diagnose the conditional keywords or the feature test macro etc. 2025-11-10 Jakub Jelinek <[email protected]> PR c++/119064 gcc/c-family/ * c-cppbuiltin.cc (c_cpp_builtins): Revert 2025-07-11 changes. gcc/cp/ * cp-tree.h (struct lang_type): Revert 2025-07-11 changes. (CLASSTYPE_TRIVIALLY_RELOCATABLE_BIT): Remove. (CLASSTYPE_TRIVIALLY_RELOCATABLE_COMPUTED): Remove. (CLASSTYPE_REPLACEABLE_BIT): Remove. (CLASSTYPE_REPLACEABLE_COMPUTED): Remove. (enum virt_specifier): Revert 2025-07-11 changes. (trivially_relocatable_type_p): Remove. (replaceable_type_p): Remove. * cp-trait.def (IS_NOTHROW_RELOCATABLE): Remove. (IS_REPLACEABLE): Remove. (IS_TRIVIALLY_RELOCATABLE): Remove. * parser.cc (cp_parser_class_specifier, cp_parser_class_head): Revert 2025-07-11 changes. * pt.cc (instantiate_class_template): Likewise. * semantics.cc (trait_expr_value): Likewise. (finish_trait_expr): Likewise. * tree.cc (default_movable_type_p): Remove. (union_with_no_declared_special_member_fns): Remove. (trivially_relocatable_type_p): Remove. (replaceable_type_p): Remove. * constraint.cc (diagnose_trait_expr): Revert 2025-07-11 changes. * module.cc (trees_out::lang_type_bools): Revert part of 2025-07-26 changes related to trivial relocatability. (trees_in::lang_type_bools): Likewise. * lex.cc (cxx_init): Don't call cpp_warn on trivially_relocatable_if_eligible and replaceable_if_eligible. gcc/testsuite/ * g++.dg/cpp26/feat-cxx26.C: Revert 2025-07-11 changes. * g++.dg/DRs/dr2581-1.C (__cpp_trivial_relocatability): Remove test. * g++.dg/DRs/dr2581-2.C (__cpp_trivial_relocatability): Likewise. * g++.dg/warn/Wkeyword-macro-1.C: Don't expect any diagnostics on #define or #undef of trivially_relocatable_if_eligible or replaceable_if_eligible. * g++.dg/warn/Wkeyword-macro-2.C: Likewise. * g++.dg/warn/Wkeyword-macro-4.C: Likewise. * g++.dg/warn/Wkeyword-macro-5.C: Likewise. * g++.dg/warn/Wkeyword-macro-7.C: Likewise. * g++.dg/warn/Wkeyword-macro-8.C: Likewise. * g++.dg/cpp26/trivially-relocatable1.C: Remove. * g++.dg/cpp26/trivially-relocatable2.C: Remove. * g++.dg/cpp26/trivially-relocatable3.C: Remove. * g++.dg/cpp26/trivially-relocatable4.C: Remove. * g++.dg/cpp26/trivially-relocatable5.C: Remove. * g++.dg/cpp26/trivially-relocatable6.C: Remove. * g++.dg/cpp26/trivially-relocatable7.C: Remove. * g++.dg/cpp26/trivially-relocatable8.C: Remove. * g++.dg/cpp26/trivially-relocatable9.C: Remove. * g++.dg/cpp26/trivially-relocatable10.C: Remove. * g++.dg/cpp26/trivially-relocatable11.C: Remove. * g++.dg/modules/class-11_a.H: Remove trivial relocatability related parts. * g++.dg/modules/class-11_b.C: Likewise.
