@speter: nope, I would like to use compiler directives to abort compilation, not to abort the application startup.
Unfortunately I don't have an answer for you but, I have a question instead. Do you happen to have a link to a page that documents all the functions that can be called at compile time ?
@440bx: hmm… no. Unfortunately, (AFAIK) the issue of directives is not fully documented. For example, the
+ operator that can be used with
DEFINED is not described, but can be used to sum results of the
DEFINED and then, test the result against the fixed number. Example:
{$IF DEFINED(FOO) + DEFINED(BAR) + DEFINED(QUX) <> 3}
{$STOP not all mandatory symbols declared}
{$ENDIF}
I ask for two reasons, I didn't know that sizeof could be used in compiler directives.
SIZEOF can be used in combination with
$IF, but I don't know if it can be used to format the error message text. That's why I'm asking, if it is possible to somehow format the message text with some integers.