[Patch, fortran] PR19260 & not required when splitting a token in continuation

Jerry DeLisle jvdelisle@verizon.net
Fri Sep 22 03:02:00 GMT 2006


:REVIEWMAIL:

The attached patch reflects addressing Tobias' comments and produces the syntax 
error for split tokens and warning for missing '&' in continued character constants.

The warning behavior is left as is based on previous discussions on the list 
quite a while ago.  The default behavior for a character constant is to continue 
just before the beginning of the non-whitespace on the next line and warn with 
-Wall, -Wampersand, -std=f95, -std=f2003, and -pedantic.

Regression tested.

OK for trunk?

Jerry

2006-09-21  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR fortran/19260
	* scanner.c (gfc_next_char_literal): Add check for missing '&'
	and set locus to old_locus when not scanning a character literal.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: pr19260b.diff
Type: text/x-patch
Size: 817 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20060922/60cc2433/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: continuation_1.f90
Type: text/x-fortran
Size: 582 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20060922/60cc2433/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: continuation_2.f90
Type: text/x-fortran
Size: 190 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20060922/60cc2433/attachment-0002.bin>


More information about the Fortran mailing list