Jump to content
  • Advertisement
Sign in to follow this  
raptorstrike

compiler wont ignor warnings

This topic is 4994 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

isnt the compile just sapposed to give you the warnings but compile any way? thats y its a warning not an error right? any way mine isnt doing that im using dev-cpp v.4.9.9.0 c++ how do i change this [smile] thx

Share this post


Link to post
Share on other sites
Advertisement
There are occasions when ignoring warnings is warranted. Offhand, I can think of two examples that I have seen: One, the retarded warning that VC++ 6.0 gives about debug symbols being too long (which doesn't provide any useful information and doesn't pertain to anything suspicious in your code), and two, a warning in a program of mine about a conversion that didn't make any sense (in a templated class where strange but harmless things happened with one particular type).

Unless you have any such particular circumstances, however, you should not ignore warnings. They are there for a reason. Personally, I always set my compiler to treat warnings as errors.

Share this post


Link to post
Share on other sites
I always compile with lots of extra warnings enabled, and the compiler set to treat warnings as errors. It warns you of things for a reason, fix what it's complaining about, or rearrange things so it's clear to you, the compiler, and anyone reading it that is really want you wanted.

I don't use -Weffc++ very often though because it tends to complain about STL, especially about base classes not having virtual destructors. But all the other warnings are pretty useful to have enabled.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!