aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/trans-array.c
diff options
context:
space:
mode:
authorAndre Vehreschild <vehre@gcc.gnu.org>2016-08-08 10:11:29 +0200
committerAndre Vehreschild <vehre@gcc.gnu.org>2016-08-08 10:11:29 +0200
commit8e9218f2b39c5730760a23595f449498f3f4faf6 (patch)
treeb3f93dd8a7175d930adc37a11b36164f595c7a41 /gcc/fortran/trans-array.c
parent1b8256df48e672430eefdd7da0071157b1a29b9c (diff)
downloadgcc-8e9218f2b39c5730760a23595f449498f3f4faf6.zip
gcc-8e9218f2b39c5730760a23595f449498f3f4faf6.tar.gz
gcc-8e9218f2b39c5730760a23595f449498f3f4faf6.tar.bz2
re PR fortran/70524 (ICE when using -frepack-arrays -Warray-temporaries)
gcc/testsuite/ChangeLog: 2016-08-08 Andre Vehreschild <vehre@gcc.gnu.org> PR fortran/70524 * gfortran.dg/dependency_48.f90: New test. gcc/fortran/ChangeLog: 2016-08-08 Andre Vehreschild <vehre@gcc.gnu.org> PR fortran/70524 * trans-array.c (gfc_trans_dummy_array_bias): Ensure that the location information is correctly set. * trans-decl.c (gfc_trans_deferred_vars): Set the locus of the current construct early. From-SVN: r239230
Diffstat (limited to 'gcc/fortran/trans-array.c')
-rw-r--r--gcc/fortran/trans-array.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/fortran/trans-array.c b/gcc/fortran/trans-array.c
index 7572755..0a66f83 100644
--- a/gcc/fortran/trans-array.c
+++ b/gcc/fortran/trans-array.c
@@ -6103,7 +6103,12 @@ gfc_trans_dummy_array_bias (gfc_symbol * sym, tree tmpdesc,
return;
}
+ loc.nextc = NULL;
gfc_save_backend_locus (&loc);
+ /* loc.nextc is not set by save_backend_locus but the location routines
+ depend on it. */
+ if (loc.nextc == NULL)
+ loc.nextc = loc.lb->line;
gfc_set_backend_locus (&sym->declared_at);
/* Descriptor type. */