4.2.4. Fail Rule

[Tip]Description

A fail rulerepresents an "always fails" instruction, that can be used for interrupting the execution of the container rule.

[Important]Syntax
FailRuleAST ::= fail ;
[Note]Semantics

The fail ruleinterrupts the execution of the container rule, which is propagated like exception to upper levels as long as it is caught (or the transformation is terminated).

An exception generated by a fail rulecan be catched explicitly by the try rule. Alternatively, a fail exception can be used to explicitly interrupt an iterate rule.

Remark.  A rule can fail in the following situations:

Defined In:  simple rule

See Also:  try rule, iterate rule