The basic elements of the Yodl grammar are identifiers, names, numbers and parameter lists.

Identifiers
are names that can have a special meaning in the Yodl language. E.g., the sequence INCLUDEFILE is such an identifier: when followed by a filename in parentheses, Yodl will take some special action (in this case, read the file). Identifiers may consist of uppercase or lowercase characters. No other characters may appear in them.

A name
is a `one-word' sequence, i.e., a series of characters where no spaces, tabs or newlines appear. E.g., the Yodl language requires a name to follow the INCLUDEFILE identifier, enclosed in parentheses.

Numbers
consist of digits. Yodl seldom uses numbers, but they are required.

Parameter lists
are the arguments that names or numbers that are arguments to a Yodl command. A parameter list must be enclosed by parentheses.
Basically, Yodl only does `something special' when it encounters a recognized identifier, followed by a parameter list. Sometimes an identifier may be followed by more than one parameter list, in that case, the action requires more than one argument. The grammar of Yodl requires that the identifier and its first parameter list follow right after each other, without intervening spaces. That means that
somemacro (argument)

will not start any Yodl action (supposing that somemacro is the name of a defined macro), since the parameter list and the identifier are separated by a space. The Yodl grammar is very strict in this sence; this rule however simplifies the parsing process of the input.

To make life easier for those who write documentation using Yodl, there may be spaces or newlines between the parameter lists (i.e., between the first and second parameter list, between the second and third, and so on). Therefore, assuming that somemacro now is defined as a macro having three arguments, the following will work:

somemacro(argument one)
    (and another argument, number two)
    (and the last one)

Summarized, an identified macro is only expanded by Yodl when it is followed by a parameter list without spaces in between. Further parameter lists may follow separated by spaces, tabs or newline characters. All required parameter lists must however be in the same input file.


Go back to index of Yodl.

Please send Yodl questions and comments to yodl@icce.rug.nl.

Please send comments on these web pages to (address unknown)

Copyright (c) 1997, 1998, 1999 Karel Kubat and Jan Nieuwenhuizen.

Verbatim copying and distribution of this entire article is permitted in any medium, provided this notice is preserved.


This page was built from Yodl-1.31.18 by

<(address unknown)>, Tue Aug 16 22:51:36 2005 EDT.