BUG: LDd Suppresses Implicit Definition of _DEBUGLast reviewed: July 24, 1997Article ID: Q163369 |
The information in this article applies to:
SYMPTOMSWhen compiler option /LDd follows /MTd, /MDd or /MLd, _DEBUG is not defined. This happens only if it is compiled from the command line. The IDE adds this definition by default in the project settings for debug build.
RESOLUTIONSpecify /LDd before /MTd, /MDd or /MLd.
STATUSMicrosoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. We are researching this bug and will post new information here in the Microsoft Knowledge Base as it becomes available.
MORE INFORMATIONWhen you use one of the compiler options /MTd, /MDd or /MLd, the symbol _DEBUG is automatically defined. However, if /LDd follows any of these options on the compiler command line, then _DEBUG is not defined automatically.
Steps to Reproduce Behavior
// x.cpp or x.c // Compile options needed to reproduce: /c /MTd /LDd // Compile options for workaround: /c /LDd /MTd #ifdef _DEBUG # pragma message("_DEBUG is defined") #else # pragma message("_DEBUG is not defined") #endif |
Keywords : CLIss kbtool vcbuglist500
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |