[patch,fortran] Fix PR19310 unnecessary error for overflowing results

Jerry DeLisle jvdelisle@verizon.net
Sat Jun 10 00:34:00 GMT 2006


Paul Brook wrote:
> On Friday 09 June 2006 18:19, Steve Kargl wrote:
> 
>>On Fri, Jun 09, 2006 at 06:01:31PM +0100, Paul Brook wrote:
>>
>>>On Friday 09 June 2006 06:47, Jerry DeLisle wrote:
>>>
>>>>+ fno-range-check
>>>>+ Fortran RejectNegative
>>>>+ Disable range checking during compilation
>>>
>>>Why no- and RejectNegative? Seem like this should be a normal option that
>>>accepts both forms (enabled by default).
>>
>>Because range checking of gfortran's constant folding is the
>>standard, everyday, setup for gfortran.  -fno-range-check
>>disables this range checking.  It is not set/unset by any other
>>option (e.g., -Wall or -std=f95), so you don't need to be
>>able to toggle range checking back on.  -fno-range-check
>>describes exactly what the option does.  If you prefer,
>>it could be -fdisable-range-check.
> 
> 
> I don't buy that argument. The same is true for several of the other -f 
> options (eg. -fbackslash) and we accept both forms of those.
> 
> Paul
> 
Well, maybe we should clarify the policy here.  I think that the only reason we 
need a negative form is in the case where a behavior is invoked by another flag 
that enables or disables more than one feature and you only want part of that 
invoked.

So we only need to turn off a feature if we need to over-ride some other 
invocation that invokes it.

In the case of -fno-range-check (or whatever you call it) the feature is 
mutually exclusive from other compiler directives and so the negative form is 
not needed.

This may be true for other cases where we have not RejectNegative and we ought 
to likewise set those RejectNegative.

Therefore, I think we ought to have the RejectNegative in this case and I should 
go back and add in for the other flags that are of this nature.

Paul, do you agree?  Steve?

Regards,

Jerry



More information about the Gcc-patches mailing list