3 ms·
These are great guidelines, but this is the second time today I've read compile with the highest warning level possible, and treat all warnings as errors. This
by hermitdev 10y ago
These are great guidelines, but this is the second time today I've read compile with the highest warning level possible, and treat all warnings as errors. This is certainly laudable, but not always possible (I try to in my own code to the greatest extent that I can). Some warnings are more informational than an actual issue. For instance, MSVC warns about functions marked inline that weren't inlined. Do I care? Depends on the situation, but its enabled at W4.
- Gibbon1 10y agoI sort of worry a little bit that the guidelines are too strict for everyday code. goto's are useful for error escape paths. I've seen rather convoluted control flow done where breaking down and using a couple of goto's would make things clean and understandable. Function pointers are immensely useful. Variadic macros are useful for implementing optional debugging statements. As in PRINTF(format, args...);
- Mayzie 10y agoclang -Weverything -Werror Buzz Lightyear voice: Errors! Errors everywhere!