This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] PR fortran/82049 -- resolve a charlen if possible
- From: Paul Richard Thomas <paul dot richard dot thomas at gmail dot com>
- To: Steve Kargl <sgk at troutmask dot apl dot washington dot edu>
- Cc: "fortran at gcc dot gnu dot org" <fortran at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 7 Feb 2018 08:10:41 +0000
- Subject: Re: [PATCH] PR fortran/82049 -- resolve a charlen if possible
- Authentication-results: sourceware.org; auth=none
- References: <20180207021706.GA39844@troutmask.apl.washington.edu>
Hi Steve,
That's OK for trunk and, if you are possessed of the intestinal
fortitude, 6- and 7-branches.
Thanks
Paul
On 7 February 2018 at 02:17, Steve Kargl
<sgk@troutmask.apl.washington.edu> wrote:
> The attached patch fixes PR fortran/82049. Prior to this
> patch, gfortran was fouling up the resolution of the charlen
> expression in the testcase. The immediately tries to resolve
> the length while parsing the type-spec.
>
> While here, I've introduced an optimization that causes
> gfc_match_type_spec() to return early if the gfortran isn't
> going to be getting a type-spec. This is done be peeking
> at the next character, if it is in [a-z], the we don't have
> a type spec. OK to commit?
>
>
> 2018-02-06 Steven G. Kargl <kargl@gcc.gnu.org>
>
> PR fortran/82049
> * match.c (gfc_match_type_spec): If the charlen is non-NULL, then
> try to resolve it. While here return early if possible.
>
> 2018-02-06 Steven G. Kargl <kargl@gcc.gnu.org>
>
> PR fortran/82049
> * gfortran.dg/assumed_charlen_parameter.f90: New test.
>
>
> --
> Steve
--
"If you can't explain it simply, you don't understand it well enough"
- Albert Einstein