https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86219

--- Comment #3 from Jason Merrill <jason at gcc dot gnu.org> ---
Author: jason
Date: Fri Jun 22 21:57:07 2018
New Revision: 261972

URL: https://gcc.gnu.org/viewcvs?rev=261972&root=gcc&view=rev
Log:
        PR c++/86219 - ICE with erroneous initializer in template.

        * constexpr.c (fold_non_dependent_expr): Add complain parm.
        * call.c, expr.c, init.c, pt.c, semantics.c, typeck.c, typeck2.c:
        Pass it.
        * call.c (build_cxx_call): Don't mess with builtins in a template.
        * typeck2.c (store_init_value): If fold_non_dependent_expr didn't
        produce a constant value, go back to the uninstantiated form.

Added:
    trunk/gcc/testsuite/g++.dg/template/conv15.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/call.c
    trunk/gcc/cp/constexpr.c
    trunk/gcc/cp/cp-tree.h
    trunk/gcc/cp/expr.c
    trunk/gcc/cp/init.c
    trunk/gcc/cp/pt.c
    trunk/gcc/cp/semantics.c
    trunk/gcc/cp/typeck.c
    trunk/gcc/cp/typeck2.c

Reply via email to