Search code examples
ibm-doors

Does DXL have a preprocessor


Is it possible to use simple pre-processor statements with DOORS DXL?

Like use #ifdef or #define?

The two main things I'm trying to do are doing pre-processed if statements (mostly for debugging purposes)

#ifdef SayHi
print "Hi"
#endif

and C like macros

#define printHi print "Hi"

Solution

  • Unfortunately not. #include looks like a preprocessing statement, but according to our analyses this statement does nothing more than decoding encrypted include files and otherwise just paste the content of the included file in place without further ado.

    When we introduced debugging into parts of our code, we more or less replaced all "print" statements in all files with a printDEBUG function call, which will print to a debug file if either a variable in a code is set to 1 or if a specific environment variable is set (that you can set before starting DOORS)