
Emil Dotchevski wrote:
On Tue, Sep 8, 2009 at 4:24 PM, Christopher Currie<christopher@currie.com> wrote:
On Tue, Sep 8, 2009 at 2:18 PM, Emil Dotchevski<emildotchevski@gmail.com> wrote:
I think that you assume that the warning is reasonable and easy to fix, as with most warnings that could be silenced with casts. A lot of times, fixing such warnings is common sense. In that case, just a note to the library developer would be enough to have it fixed.
But you can't generalize from this, to "all warnings should be silenced."
On the other hand, many people work in environments where there is a local policy that warnings will be treated as errors. If library code emits warnings, the build breaks and the library is unusable.
I agree this is a very strong argument, and you're right that even though such policy is unreasonable, it may render a library basically unusable.
Why is such policy unreasonable? Suppose that building a source file that uses Boost libraries produces 100 warnings from Boost code. Can you suggest a reasonable strategy how a developer can spot the warnings in their own code amids the pages of warnings from Boost? For bonus points, assume that Boost is not installed system-wide, but is included in the project, possibly with local tweaks. - Volodya