Type:
MACRO: integer x expr_block -> function
Call syntax:
MACRO(nrOfParams,
macroBody)
Description:
Returns an nrOfParams-place macro which is defined by
block macroBody.
Macros are a variant of functions; they behave identically in all respects despite that they don't generally have local variables. Only the variables named $... are local, among these the actual parameters of the macro. Thus, within macro-bodies, global variables can be modified.
Attention!
Example:
> x := 3;
> f := MACRO(2, `x := 1; write("x=",x)´)
> f(0);
x=3
Result = 3