https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70776
Richard Biener changed:
What|Removed |Added
Priority|P3 |P2
Status|UNCONFIRMED |NEW
Last reconfirmed||2016-04-25
Ever confirmed|0 |1
--- Comment #2 from Richard Biener ---
Confirmed. Infinite recursion via
#0 0x00b0051e in ggc_internal_alloc (
size=, f=,
s=,
n=)
at /space/rguenther/src/svn/trunk/gcc/ggc-page.c:1267
#1 0x00d3e569 in ggc_internal_cleared_alloc (size=40, f=0x0, s=0, n=1)
at /space/rguenther/src/svn/trunk/gcc/ggc-common.c:116
#2 0x013e9456 in ggc_internal_cleared_alloc (s=40)
at /space/rguenther/src/svn/trunk/gcc/ggc.h:148
#3 0x013e948a in ggc_alloc_cleared_tree_node_stat (s=40)
at /space/rguenther/src/svn/trunk/gcc/ggc.h:292
#4 0x013ef8c2 in make_tree_vec_stat (len=2)
at /space/rguenther/src/svn/trunk/gcc/tree.c:2281
#5 0x0081467f in coerce_template_parms (
parms=, args=,
in_decl=, complain=0,
require_all_args=true, use_default_args=true)
at /space/rguenther/src/svn/trunk/gcc/cp/pt.c:7594
#6 0x008151a1 in coerce_innermost_template_parms (
parms=, args=,
in_decl=, complain=0,
require_all_args=true, use_default_args=true)
at /space/rguenther/src/svn/trunk/gcc/cp/pt.c:7820
#7 0x00817ceb in lookup_template_class_1 (
d1=, arglist=,
in_decl=, context=,
entering_scope=0, complain=0)
at /space/rguenther/src/svn/trunk/gcc/cp/pt.c:8297
#8 0x0081ae6b in lookup_template_class (
d1=, arglist=,
in_decl=, context=,
entering_scope=0, complain=0)
at /space/rguenther/src/svn/trunk/gcc/cp/pt.c:8638
#9 0x008274a3 in tsubst_aggr_type (t=,
args=, complain=0, in_decl=,
entering_scope=0) at /space/rguenther/src/svn/trunk/gcc/cp/pt.c:11425
#10 0x0082fe5d in tsubst (t=,
args=, complain=0, in_decl=)
at /space/rguenther/src/svn/trunk/gcc/cp/pt.c:12895
#11 0x00833e7d in tsubst_qualified_id (
qualified_id=, args=,
complain=0, in_decl=, done=true, address_p=false)
at /space/rguenther/src/svn/trunk/gcc/cp/pt.c:13734
...
Clang detects:
> clang++ -S t.ii
t.ii:6:34: fatal error: recursive template instantiation exceeded maximum depth
of 256
Not sure if the testcase is thus invalid (but we should diagnose it instead
of crashing).