This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
[RFH]: too many trees in the forest
- From: Steve Kargl <sgk at troutmask dot apl dot washington dot edu>
- To: fortran at gcc dot gnu dot org
- Date: Fri, 24 Jul 2009 20:39:29 -0700
- Subject: [RFH]: too many trees in the forest
OK, so who's the tree expert among us?
I have written code that parses
program a
integer, allocatable :: i(:)
allocate(i(4), source=42)
end program a
gfc_trans_allocate() already correctly allocates the memory for i(:).
I've added
/* SOURCE block. */
if (code->expr3)
{
gfc_init_se (&src, NULL);
gfc_conv_expr (&src, code->expr3); /*sgk*/
gfc_add_expr_to_block (&block, tmp);
}
which converts the gfc_expr code->expr3 to a gfc_se. In scanning
through the trans-*c files, I can't find any function that assigns
src to se.expr (the gfc_se for i(:)). So, how do I populate i(1:5)
to 42.
--
Steve