[Bug c++/56684] New: [4.8 Regression] [C++0x] ICE: unexpected expression 'T' of kind template_parm_index
zsojka at seznam dot cz
gcc-bugzilla@gcc.gnu.org
Thu Mar 21 20:26:00 GMT 2013
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56684
Bug #: 56684
Summary: [4.8 Regression] [C++0x] ICE: unexpected expression
'T' of kind template_parm_index
Classification: Unclassified
Product: gcc
Version: 4.8.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: zsojka@seznam.cz
Created attachment 29705
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29705
reduced testcase
Compiler output:
$ gcc -std=gnu++0x testcase.C
testcase.C: In constructor 'S<T>::S()':
testcase.C:4:11: internal compiler error: unexpected expression 'T' of kind
template_parm_index
S() { 1 << Ti; }
^
0x72e441 cxx_eval_constant_expression
/mnt/svn/gcc-trunk/gcc/cp/semantics.c:8106
0x731446 cxx_eval_outermost_constant_expr
/mnt/svn/gcc-trunk/gcc/cp/semantics.c:8126
0x7342e7 maybe_constant_value(tree_node*)
/mnt/svn/gcc-trunk/gcc/cp/semantics.c:8237
0x6ddc84 cp_build_binary_op(unsigned int, tree_code, tree_node*, tree_node*,
int)
/mnt/svn/gcc-trunk/gcc/cp/typeck.c:4148
0x5b81f7 build_new_op_1
/mnt/svn/gcc-trunk/gcc/cp/call.c:5399
0x5b8b27 build_new_op(unsigned int, tree_code, int, tree_node*, tree_node*,
tree_node*, tree_node**, int)
/mnt/svn/gcc-trunk/gcc/cp/call.c:5444
0x6cb8e2 build_x_binary_op(unsigned int, tree_code, tree_node*, tree_code,
tree_node*, tree_code, tree_node**, int)
/mnt/svn/gcc-trunk/gcc/cp/typeck.c:3684
0x60495a tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
/mnt/svn/gcc-trunk/gcc/cp/pt.c:13685
0x608154 fold_non_dependent_expr_sfinae(tree_node*, int)
/mnt/svn/gcc-trunk/gcc/cp/pt.c:5071
0x6082ac build_non_dependent_expr(tree_node*)
/mnt/svn/gcc-trunk/gcc/cp/pt.c:20446
0x713540 finish_expr_stmt(tree_node*)
/mnt/svn/gcc-trunk/gcc/cp/semantics.c:616
0x6a4027 cp_parser_statement
/mnt/svn/gcc-trunk/gcc/cp/parser.c:8941
0x6a52be cp_parser_statement_seq_opt
/mnt/svn/gcc-trunk/gcc/cp/parser.c:9207
0x6a5406 cp_parser_compound_statement
/mnt/svn/gcc-trunk/gcc/cp/parser.c:9161
0x6b6843 cp_parser_function_body
/mnt/svn/gcc-trunk/gcc/cp/parser.c:17776
0x6b6843 cp_parser_ctor_initializer_opt_and_function_body
/mnt/svn/gcc-trunk/gcc/cp/parser.c:17812
0x6b78cf cp_parser_function_definition_after_declarator
/mnt/svn/gcc-trunk/gcc/cp/parser.c:21787
0x69dfdc cp_parser_late_parsing_for_member
/mnt/svn/gcc-trunk/gcc/cp/parser.c:22428
0x69dfdc cp_parser_class_specifier_1
/mnt/svn/gcc-trunk/gcc/cp/parser.c:18535
0x69dfdc cp_parser_class_specifier
/mnt/svn/gcc-trunk/gcc/cp/parser.c:18559
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.
Tested revisions:
r196855 - crash
More information about the Gcc-bugs
mailing list