From a17b4d4c608e1336cbde0b7035efffe9fadadd83 Mon Sep 17 00:00:00 2001 From: Paul Thomas Date: Sun, 20 May 2018 10:54:24 +0000 Subject: [PATCH] re PR fortran/82275 (gfortran rejects valid & accepts invalid reference to dimension-remapped type SELECT TYPE selector) 2018-05-20 Paul Thomas PR fortran/82275 Correcting ChangeLogs * match.c (gfc_match_type_spec): Go through the array ref and decrement 'rank' for every dimension that is an element. 2018-05-20 Paul Thomas PR fortran/82275 Correcting ChangeLogs * gfortran.dg/select_type_42.f90: New test. From-SVN: r260416 --- gcc/fortran/ChangeLog | 20 +++++++++++++++++--- gcc/testsuite/ChangeLog | 15 +++++++++------ 2 files changed, 26 insertions(+), 9 deletions(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 8e6c933d7c7..c5e1aa823e5 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,13 @@ +2018-05-20 Paul Thomas + + PR fortran/80657 + * resolve.c (flag_fn_result_spec): Use the 'sym' argument to + test for self refs to the function result in the character len + expression. If a self reference is found, emit an error and + return true. + (resolve_fntype): Use the function symbol in the calls to the + above. + 2018-05-20 Paul Thomas PR fortran/49636 @@ -5,6 +15,8 @@ 'get_array_span'. (gfc_conv_expr_descriptor): Change references to above. * trans-array.h : Add prototype for 'gfc_get_array_span'. + * trans-intrinsic.c (gfc_conv_associated): Add pre and post + blocks for 'arg1'. * trans-stmt.c (trans_associate_var): If the associate name is a subref array pointer, use gfc_get_array_span for the span. @@ -17,9 +29,11 @@ 2018-05-19 Paul Thomas PR fortran/82923 - * gfortran.dg/allocate_assumed_charlen_4.f90: New test. Note - that the patch fixes PR66694 & PR82617, although the testcases - are not explicitly included. + PR fortran/66694 + PR fortran/82617 + * trans-array.c (gfc_alloc_allocatable_for_assignment): Set the + charlen backend_decl of the rhs expr to ss->info->string_length + so that the value in the current scope is used. 2018-05-13 Steven G. Kargl diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index b919b842aa8..7866b3524e0 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2018-05-20 Paul Thomas + + PR fortran/80657 + * gfortran.dg/char_result_18.f90: New test. + 2018-05-20 Paul Thomas PR fortran/49636 @@ -5,17 +10,15 @@ 2018-05-20 Paul Thomas - PR fortran/82923 + PR fortran/82275 * gfortran.dg/select_type_42.f90: New test. 2018-05-19 Paul Thomas PR fortran/82923 - PR fortran/66694 - PR fortran/82617 - * trans-array.c (gfc_alloc_allocatable_for_assignment): Set the - charlen backend_decl of the rhs expr to ss->info->string_length - so that the value in the current scope is used. + * gfortran.dg/allocate_assumed_charlen_4.f90: New test. Note + that the patch fixes PR66694 & PR82617, although the testcases + are not explicitly included. 2018-05-18 Kito Cheng -- 2.30.2