This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
[PATCH] PR fortran/68053 -- Reduce initialization expression to constant value
- From: Steve Kargl <sgk at troutmask dot apl dot washington dot edu>
- To: fortran at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Sun, 8 Nov 2015 14:35:58 -0800
- Subject: [PATCH] PR fortran/68053 -- Reduce initialization expression to constant value
- Authentication-results: sourceware.org; auth=none
The attached patch has been built and regression tested
on i386-*-freebsd and x86_64-*-freebsd. If an array
index in an initialization expression is an array element
from an array named constant, the array index needs to be
reduced. This patch causes the reduction to occur.
OK to commit?
2015-11-08 Steven g. Kargl <kargl@gcc.gnu.org>
PR fortran/68053
* decl.c (add_init_expr_to_sym): Try to reduce initialization expression
before testing for a constant value.
2015-11-08 Steven g. Kargl <kargl@gcc.gnu.org>
PR fortran/68053
* gfortran.dg/pr68053.f90: New test.
--
Steve