B.2.1 Looped Code Generation



next up previous contents
Next: B.2.2 Conditional Code Generation Up: B.2 The UNFUG Syntax Previous: B.2 The UNFUG Syntax

B.2.1 Looped Code Generation

UNFUG starts using the tuple tuple-name for generating code enclosed in the UseTuple - EndTuple pair in a loop, assigning the values to the LISP variable names in the tuple as many times as lists of values are contained in the tuple. This is the main construct which is used for repeated code segments having the same skeleton but vary in the details. UNFUG's name (Universal Function Generator) stems from this concept of a loop being run over a template function.

Note that both the UseTuple as well as the EndTuple statements itself produce no output at all (i.e. the empty string); all output results from the repeated application of the UNFUG evaluator to the enclosed code.



Martin Stiftinger
Tue Nov 29 19:41:50 MET 1994