[Bug fortran/40963] ICE segfault - c_loc with derived type component as argument
burnus at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Tue Aug 4 16:14:00 GMT 2009
------- Comment #2 from burnus at gcc dot gnu dot org 2009-08-04 16:14 -------
The issue is that the expression is an array ("expr->rank > 0") but the symbol
itself is not, only it's component.
==16545== Invalid read of size 4
==16545== at 0x55343F: gfc_conv_procedure_call (trans-expr.c:2441)
==16545== by 0x547595F: ???
==16545== by 0x4FBD06: gfc_match_actual_arglist (primary.c:1670)
That's the last line in:
if (sym->intmod_sym_id == ISOCBINDING_LOC)
[...]
if (arg->expr->rank == 0)
gfc_conv_expr_reference (se, arg->expr);
else
{[...]
/* We should want it to do g77 calling convention. */
f = (fsym != NULL)
&& !(fsym->attr.pointer || fsym->attr.allocatable)
&& fsym->as->type != AS_ASSUMED_SHAPE;
--
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-04 16:14:31
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40963
More information about the Gcc-bugs
mailing list