This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/32682] [4.3 Regression] ICE in gfc_trans_array_constructor, at fortran/trans-array.c:1664



------- Comment #7 from fxcoudert at gcc dot gnu dot org  2007-07-28 20:47 -------
(In reply to comment #3)
> Index: gcc/fortran/trans-array.c
> ===================================================================
> *** gcc/fortran/trans-array.c   (revision 126461)
> --- gcc/fortran/trans-array.c   (working copy)
> *************** gfc_trans_array_constructor (gfc_loopinf
> *** 1656,1661 ****
> --- 1656,1673 ----
> 
>     /* See if the constructor determines the loop bounds.  */
>     dynamic = false;
> +
> +   if (ss->expr->shape && loop->to[0] == NULL_TREE)
> +     {
> +       int n;
> +       for (n = 0; n < ss->expr->rank; n++)
> +       {
> +         loop->to[n] = gfc_conv_mpz_to_tree (ss->expr->shape [n],
> +                                             gfc_index_integer_kind);
> +         loop->from[n] = gfc_index_zero_node;
> +       }
> +     }
> +
>     if (loop->to[0] == NULL_TREE)
>       {
>         mpz_t size;

This is OK to commit.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32682


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]