This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch, fortram] PR64506 FORMAT Parse Error with Continuation Line
- From: Tobias Burnus <burnus at net-b dot de>
- To: Jerry DeLisle <jvdelisle at charter dot net>, gfortran <fortran at gcc dot gnu dot org>, gcc patches <gcc-patches at gcc dot gnu dot org>
- Date: Sun, 01 Feb 2015 22:02:24 +0100
- Subject: Re: [patch, fortram] PR64506 FORMAT Parse Error with Continuation Line
- Authentication-results: sourceware.org; auth=none
- References: <54CE1FAA dot 8040703 at charter dot net>
Jerry DeLisle wrote:
The attached patch fixes this issue.
Regression tested on x86-64.
New test case attached.
OK for trunk?
Looks ok (together with a changelog for the test case).
However, I tried a similar fixed-form program and it failed similarly. I
think you need a similar fix (in the same function) for fixed-form
source code. See attachment for an example.
Tobias
2015-02-01 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/64506
* scanner.c (gfc_next_char_literal): Check for '!' and if found,
clear the comment and go back and get the next character.
100 format('This format is OK.'
&)
200 format('This format fails.'!comment << FAILS
&)
300 format('This format fails.' !comment
&)
400 format('This format is OK.' !comment
&)
500 format('This format is OK.' !comment
&)
end