[Patch, fortran] Fix PR19101 missing & in character continuation not caught

Jerry DeLisle jvdelisle@verizon.net
Thu Mar 9 06:02:00 GMT 2006


:REVIEWPATCH:

The attached is a revised patch following example of Steve's evil tab.  You will 
see the tabs flag in there.  I won't commit this until after Steve commits his 
so we don't bump into each other.  Whats nice about this is the compiler takes a 
good approach when the ampersand is missing and continues the string at the 
first non-whitespace character.  If -pedantic is given, it does the same thing 
but issues a warning allowing users to fix if they wish.

I think this is a good way to go.  OK for trunk and 4.1.1?  I will commit after 
Steve's tab error patch.

2006-03-08  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR fortran/19101
	* gfortran.h: Add flag_ampersand.
	* options.c (gfc_init_options): Initialize flag_ampersand.
	(gfc_post_options): Set the flag if pedantic.
	* scanner.c (gfc_next_char_literal): Add test for missing '&' in
	continued character constant and give warning if missing and
	pedantic.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pr19101.diff
Type: text/x-patch
Size: 1646 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20060309/eba61bbf/attachment.bin>


More information about the Fortran mailing list