https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93340

--- Comment #7 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Harald Anlauf <anl...@gcc.gnu.org>:

https://gcc.gnu.org/g:bdd1b1f55529da00b867ef05a53a08fbfc3d1c2e

commit r11-6687-gbdd1b1f55529da00b867ef05a53a08fbfc3d1c2e
Author: Harald Anlauf <anl...@gmx.de>
Date:   Thu Jan 14 20:25:33 2021 +0100

    PR fortran/93340 - fix missed substring simplifications

    Substrings were not reduced early enough for use in initializations,
    such as DATA statements.  Add an early simplification for substrings
    with constant starting and ending points.

    gcc/fortran/ChangeLog:

            * gfortran.h (gfc_resolve_substring): Add prototype.
            * primary.c (match_string_constant): Simplify substrings with
            constant starting and ending points.
            * resolve.c: Rename resolve_substring to gfc_resolve_substring.
            (gfc_resolve_ref): Use renamed function gfc_resolve_substring.

    gcc/testsuite/ChangeLog:

            * substr_10.f90: New test.
            * substr_9.f90: New test.

Reply via email to