https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95066
--- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-10 branch has been updated by Marek Polacek <mpola...@gcc.gnu.org>: https://gcc.gnu.org/g:ae275b986b8cc747a5b4f389cb05a71fdee1f886 commit r10-8280-gae275b986b8cc747a5b4f389cb05a71fdee1f886 Author: Marek Polacek <pola...@redhat.com> Date: Thu Jun 11 16:33:13 2020 -0400 c++: explicit(bool) malfunction with dependent expression [PR95066] I forgot to set DECL_HAS_DEPENDENT_EXPLICIT_SPEC_P when merging two function declarations and as a sad consequence, we never tsubsted the dependent explicit-specifier in tsubst_function_decl, leading to disregarding the explicit-specifier altogether, and wrongly accepting this test. PR c++/95066 * decl.c (duplicate_decls): Set DECL_HAS_DEPENDENT_EXPLICIT_SPEC_P. * g++.dg/cpp2a/explicit16.C: New test.