*ping* Re: [Patch, Fortran+testsuite] PR 47750 - distinguish dg-error and dg-warning in Fortran

Jerry DeLisle jvdelisle@frontier.com
Fri Feb 18 15:43:00 GMT 2011


On 02/17/2011 11:10 PM, Tobias Burnus wrote:
> * ping*
>
> Tobias
>
> Tobias Burnus wrote:
>> The attached patch fixes the long-standing problem that gfortran's testsuite
>> does not distinguish between dg-error and dg-warning. This was fixed a couple
>> of years ago for C but never for Fortran.
>>
>> The issue was raised again in PR 45743 - and split off into the separate PR
>> 47750.
>>
>> The attached patch sets the "Error:" and "Warning:" prefix and fixes the fall
>> out. In particular, lib/gcc-dg.exp seems to expect that there is always a line
>> number and a column number. And gfortran's line numbers can be complicated
>> such as "file:line.8-12:" if one has two error locations [(1) and (2)] in the
>> same line. Furthermore, gcc-dg recognizes ":" instead of "." as line-column
>> separator. (Remember also that some of the errors are generated via the middle
>> end.)
>>
>> Besides the lib/* changes, I had also to modify several test cases. I have not
>> checked whether warning vs. error makes sense. In particular, I have the
>> feeling that for PR 45743 an error would be more suitable. Thus, if you review
>> the patch, you could look also at the changes and fill a PR if you think a
>> warning should be an error or vice versa.
>>
>> Regtested on x86-64-linux.
>> OK for the trunk?
>>
>> Tobias

Yes, OK, thanks for patch.

Jerry



More information about the Fortran mailing list