Mail Archives: djgpp-workers/2001/06/10/06:05:25
On Sun, 10 Jun 2001, Tim Van Holder wrote:
> > GCC is complaining because we asked it to with -Wconversion. I think
> > -Wconversion is useful because it flags code that could break if small
> > changes are introduced into the code.
>
> >From what has been said, it would only break if chars, shorts or floats
> were passed to a function without a prototype.
As I wrote, they also break if you convert a normal function to a vararg
function.
> IMHO, the annoyance of getting this kind of warning far outweighs the
> usefulness of getting 'x = -1' (where x is unsigned) flagged (the only
> other effect of -Wconversion).
Unlike other warnings, this one is so easy to fix that I wouldn't call it
annoyance.
Compare this with the `char *' vs `const char *' issue--we went as far as
inventing a special trick, just to be able to use one of -Wall's warnings.
Even the signed vs unsigned problems that Martin just fixed are much
trickier than this one.
For such a low price, I fail to see why is this flag met with such a
staunch opposition. Are you saying that it is useless in general, and
that GCC maintainers should have never added it?
- Raw text -