Warning raised in debug mode but not release mode
-
I hope this is an easy one for someone more familiar with the VS8 IDE than me. There was a local variable in my code that was initialized but not referenced and so warning C4189 (level 4) was raised. However, it was only raised when compiling in debug mode. In release mode the warning was not raised. I have the following properties set in my project, under Configuration Properties > C/C++ > General: Warning Level = Level 4 Treat Warnings As Errors = Yes I have triple checked, and these settings are the same for debug and release configurations. I have corrected the bug, but any ideas why the warning was not raised in release mode?
-
I hope this is an easy one for someone more familiar with the VS8 IDE than me. There was a local variable in my code that was initialized but not referenced and so warning C4189 (level 4) was raised. However, it was only raised when compiling in debug mode. In release mode the warning was not raised. I have the following properties set in my project, under Configuration Properties > C/C++ > General: Warning Level = Level 4 Treat Warnings As Errors = Yes I have triple checked, and these settings are the same for debug and release configurations. I have corrected the bug, but any ideas why the warning was not raised in release mode?
It's possible that the variable is optimised out of your release build.
Darka [Xanya] "I am not a slave to a god that doesn't exist."