"The value changed at ++index is never used"

Ok, Ive run this past several colleagues here, and we all think that this is a bad call :

Code such as :

foo.bar( ++index );

being flagged as a warning with the following message: "The changed at ++index is never used"

we think is incorrect.

The value changed at ++index is used.

Im also aware that this was discussed a couple of weeks back, but nothing seemed to come of that.

So, can we at least get a config option to disable this warning, or, better (as far as we see), get this fixed so that such usage of the pre-increment operator is not flagged as a warning.


Comment actions Permalink

File a bug report about it. I tried it already and couldn't convince them to change it, but maybe you've more luck.

I absolutely agree with you that this shouldn't be flagged as a warning.

Comment actions Permalink

Agree as well.

See the historical debate here

I see that everybody who has chimed in this time round already commented
last time, so I won't add anything!

PS I give the last word to
rather than bytecode analysis ...


Please sign in to leave a comment.