Next: , Previous: PRS Rule Macros, Up: PRS


11.5 Rule Attributes

(I don't know the grammar for rule attributes in CAST.) In HAC-PRS, production rules may be tagged with an arbitrary number of attributes.

The most common example is the after delay attribute, which was written in CAST:

     after 100  p -> q+

which would now be written in HAC:

     [after=100]  p -> q+

Attributes appear as a semicolon-delimited, square-bracket-enclosed list of key-value pairs prefixing the rule. An example of multiple attributes:

     [after=100;weak=1]  p -> q+

Attributes that appear before a loop-enclosed rule will apply to all iterations of the looped rule. The expressions in attributes may be parameter-dependent or induction-variable dependent, resulting in different values per iteration.