FILE ... TOC

Evaluate a macro

Evaluate the macro given as a string reference. Returns the result as a string.

Usage:

            $output .= &EvalMacro(\$string,$filename,$level)

$filename is used merely to resolve relative file references in include macros.

The third parameter $level gives the actual deepness of the code. This is zero for characters coming from the input file. It is n for characters generated by macros of the level n-1. It is used to track line numbers for error messages.

This function first checks if there is a @verbatim modifier before the macro name.

After this: if the macro starts with # or @ then it is a built in macro otherwise this is user defined or predefined macro (functinally there are no differences).

Finally DoInput is called in most cases to resolve macros in the resulted string.

When a macro starts with the $ character it is a loop macro and is processed only if it is in a loop. Otherwise the result is the macro itself.

FILE ... TOC