Unfortunately not. Here is the doc [1]:
"To enable debugging in C#, add the /d:DEBUG flag to the compiler command
line when you compile your code, or add #define DEBUG to the top of your
file. In Visual Basic, add the /d:DEBUG=True flag to the compiler command
line. To provide equivalent functionality in C++, you must enclose calls to
methods of this class in a #ifdef DEBUG... #endif block. This syntax is
compiler-specific. If you are using a compiler other than the ones specified
above, you must refer to the compiler's documentation to enable conditional
compiling because of the conditional compilation attributes placed on the
methods of Debug.
"
Marcus Heege
www.heege.net
"adhingra" <ad******@discu ssions.microsof t.com> wrote in message
news:8F******** *************** ***********@mic rosoft.com...
I stumbled upon something which does not make sense "Debug class methods
are
not automatically suppressed by the managed c++ compiler when the project
is
build in release mode"
Create a a Project (Windiows Forms or Console) in VS2005 using Managed
C++
and put a Debug:;Assert(f alse) or Debug::Writelin e("test") in there and
then
compile in Debug and release Configurations. The result is the same in
both.
Debug class calls are not automatically suppressed in release
configuration.
Is there some project setting that i need to set to get this to work? Any
help here is appreciated
thx
ashoo