echo

Sends a string or mathematical expression to the standard error stream.

Syntax

echo(expr)

Input

expr
A string or mathematical expression.

Example

Template:
{dx=0}
{if (dx==0)
echo("ERROR: Divide by zero")
else
a = 1/dx
endif}

Output:

ERROR: Divide by zero

Comments

When Templex encounters an echo statement in a template, expr is written to the stderr stream, unlike other Templex output which is written to stdout. This makes the echo statement useful for debugging templates. Each echo statement generates a new line.