*ping* Re: [PATCH] PR fortran/89103 - Allow blank format items in format strings
Mark Eggleston
mark.eggleston@codethink.co.uk
Mon Jun 10 13:33:00 GMT 2019
On 10/06/2019 11:30, Thomas Koenig wrote:
> Hi Mark,
>
>> +++ b/gcc/fortran/io.c
>> @@ -756,6 +756,16 @@ format_item_1:
>> Â Â Â Â Â Â Â error = unexpected_end;
>> Â Â Â Â Â Â Â goto syntax;
>> Â +Â Â Â case FMT_RPAREN:
>> +Â Â Â Â Â /* Oracle allows a blank format item. */
>> +Â Â Â Â Â if (flag_dec_blank_format_item)
>> +Â Â Â goto finished;
>> +Â Â Â Â Â else
>> +Â Â Â {
>> +Â Â Â Â Â error = unexpected_element;
>> +Â Â Â Â Â goto syntax;
>> +Â Â Â }
>> +
>
> If we make an extra effort to support this non-standard code, we
> could at least use this to generate a more informative error message
> (which could also point to the option that would allow this extension).
This patch is for a customer that has a huge codebase and that is the
only reason for its existence. The error message has not changed. Making
it more informative, indicating an option that will allow this
non-standard usage, is a bad idea as it could result in its spread. As
is the case with all legacy features and extensions their inclusion
risks pollution of Fortran code with non-standard features which is why
they should only be available using explicit compiler options.
>
> Regards
>
> Â Â Â Â Thomas
>
--
https://www.codethink.co.uk/privacy.html
More information about the Fortran
mailing list