This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Patch, Fortran] PR 82018: -Wextra should imply -Wconversion-extra


> Le 19 sept. 2017 à 21:59, Thomas Koenig <tkoenig@netcologne.de> a écrit :
> 
> Am 18.09.2017 um 11:50 schrieb Dominique d'Humières:
>> Warning: Conversion from 'REAL(4)' to 'REAL(8)' at (1) [-Wconversion-extra]
> 
> Not me (not in the general case)
> 
>> even if may allow to detect things such as ‘pi8=acos(-1.0)’?
> 
> This one would be interesting to catch (even with -Wall), although
> it would be hard to avoid false positives.
> 
> I agree with Dominique that enabling -Wconversion-extra
> the way it is now would be too noisy.
> 
> Are there warnings currently enabled with -Wconversion-extra
> which would be useful in -Wextra (or even ones currently not in
> -Wconversion-extra) without having too many false positives?
> 
> r8 = 1./3. could be one example, r8=acos(-1.0) another.  Something
> like "it must have been calculated with a formula and, if evaluated
> in the precision of the lhs, gives a different result from the one
> if the user had specified it with the correct precision".
> 
> We don't do that yet, but I think it could be useful even with -Wall,
> and certainly with -Wextra.
> 
> What do you think?

Is it really worth the trouble?

I am really upset by the time spent on warning at the expense of more serious problems.

Dominique


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]