https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108104
--- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-12 branch has been updated by Patrick Palka <ppa...@gcc.gnu.org>: https://gcc.gnu.org/g:6e09ca0cba625b8bb2ef50f9df726eb455ebb813 commit r12-8997-g6e09ca0cba625b8bb2ef50f9df726eb455ebb813 Author: Patrick Palka <ppa...@redhat.com> Date: Thu Dec 15 15:38:47 2022 -0500 c++: partial ordering with memfn ptr cst [PR108104] Here we're triggering an overzealous assert in unify during partial ordering since the member function pointer constants are represented as ordinary CONSTRUCTORs (with TYPE_PTRMEMFUNC_P TREE_TYPE) but the assert expects COMPOUND_LITERAL_P constructors. PR c++/108104 gcc/cp/ChangeLog: * pt.cc (unify) <default>: Relax assert to accept any CONSTRUCTOR parm, not just COMPOUND_LITERAL_P one. gcc/testsuite/ChangeLog: * g++.dg/template/ptrmem33.C: New test. (cherry picked from commit 38304846d18d6bb14b0fd6c627c5c6d43a814d01)