[ros-dev] [ros-diffs] [sginsberg] 41436: - In Win32 DBG is defined to 0 for a non-debug build and to 1 for a debug build. In ReactOS we do this slightly different: DBG is correctly defined to 1 for debug, but not defined at all on non-debug/release build. Because gcc is awesome we can then check for debug compilation with both #ifdef DBG and #if DBG (error free! yay gcc!), and so we have mixed usage all over the tree. - Fix this by defining DBG on non-debug build too and deprecate all usage of #ifdef DBG.

Sarocet sarocet at gmail.com
Mon Jun 22 16:13:25 CEST 2009


Timo Kreuzer wrote:
> sginsberg at svn.reactos.org wrote:
>   
>> Author: sginsberg
>> Date: Wed Jun 17 16:44:05 2009
>> New Revision: 41436
>>
>> [...] Because gcc is awesome we can then check for debug compilation with both #ifdef DBG and #if DBG (error free! yay gcc!), and so we have mixed usage all over the tree
>>     
> MSVC behaves exactly the same way ;-P
>   

Doesn't the standard specify that a #if against an undefined macro works
as if that macro were 0?



More information about the Ros-dev mailing list