[Bug fortran/95544] ICE in gfc_can_put_var_on_stack, at fortran/trans-decl.c:494
sgk at troutmask dot apl.washington.edu
gcc-bugzilla@gcc.gnu.org
Thu Jun 4 23:06:34 GMT 2020
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95544
--- Comment #4 from Steve Kargl <sgk at troutmask dot apl.washington.edu> ---
Likely, want to include this in the commit if someone ever gets
around to committing the patch(es).
Index: gcc/fortran/misc.c
===================================================================
--- gcc/fortran/misc.c (revision 280157)
+++ gcc/fortran/misc.c (working copy)
@@ -252,7 +252,8 @@ gfc_dummy_typename (gfc_typespec *ts)
has_length = ts->u.cl->length != NULL;
if (!has_length)
{
- if (ts->kind == gfc_default_character_kind)
+ if (ts->kind == gfc_default_character_kind
+ || ts->kind == 0)
sprintf(buffer, "CHARACTER(*)");
else if (ts->kind < 10)
sprintf(buffer, "CHARACTER(*,%d)", ts->kind);
More information about the Gcc-bugs
mailing list