This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/41167] ICE with PACK() and string concatenation
- From: "burnus at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 25 Aug 2009 17:02:14 -0000
- Subject: [Bug fortran/41167] ICE with PACK() and string concatenation
- References: <bug-41167-6318@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from burnus at gcc dot gnu dot org 2009-08-25 17:02 -------
> internal compiler error: in gfc_typenode_for_spec
That's the unreachable() due to: spec->type == BT_UNKNOWN.
Debugging shows that gfc_typenode_for_spec is called by
gfc_conv_expr_descriptor where erxp->expr_type == EXPR_OP and expr->value.op.op
== INTRINSIC_CONCAT.
One has:
default:
/* Something complicated. Copy it into a temporary. */
need_tmp = 1;
and then:
if (need_tmp)
{
if (expr->ts.type == BT_CHARACTER
&& !expr->ts.u.cl->backend_decl)
get_array_charlen (expr, se);
loop.temp_ss->data.temp.type = gfc_typenode_for_spec (&expr->ts);
Thus everything which is BT_UNKNOWN will fail here. I do not see ad hoc whether
this can only be the concat operator or any operator, but I wouldn't be
surprised if this were a more general problem.
--
burnus at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Keywords| |ice-on-valid-code
Last reconfirmed|0000-00-00 00:00:00 |2009-08-25 17:02:14
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41167