PickBASIC / FlashBASIC
$DEFINE directive
.mdThe $DEFINE directive supplies replacement text for a symbol and defines a symbol used to control the compilation of the program.
Syntax
$DEFINE identifier {replacement-text}
Parameter(s)
| identifier | Specifies the symbol to be defined. |
| replacement-text | Specifies a string of characters that the compiler uses to replace each occurrence of the symbol in the current program. The replacement-text parameter is terminated by a RETURN. |
Description
A single space separates the identifier from the replacement text. Every character that
appears after this space, and up to (but not including) the RETURN character, is considered part
of the replacement-text parameter. This includes any comments that might
appear on the same line as the $DEFINE directive.
Important: Do not include comments
on the same line as the $DEFINE directive. Text appearing on the same line
as the $DEFINE directive after the identifier plus one space is used as
replacement text.
When used to replace symbol text, the specified identifier and any associated replacement text is added to the symbol table. Every occurrence of the symbol following the $DEFINE directive is replaced by the replacement text. If no replacement text is specified, the symbol is defined with a value of null.