In full debug mode, C++Builder also defines a DEBUG
conditional that can be tested with #ifdef
statements. You can see it present in the Conditionals list in the Project Options.
Does C++Builder 6 include a "DEBUG" macro or a similar facility?
-
01-06-2022 - |
Question
With GCC it's possible to pass a command-line flag like -DDEBUG
and then use conditionals like #ifdef DEBUG
. C++Builder 6 has a built-in notion of "debug mode" vs. "release mode"; is there any way to determine (preferably from within the preprocessor) which mode the application is being built in?
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow