Eliminate - grammarware/slps GitHub Wiki
An unused definition (at most used within the definition itself) is removed. The undefine operator should be used instead when the definition must be removed despite remaining uses. The removeV operator should be used instead when only part of the definition (i.e., a production of a vertical definition) is to be removed.
Syntax
eliminate:
nonterminal::nonterminal
Example
For instance,
expr:
int
intexpr:
int
After using this transformation:
eliminate(intexpr);
Will look like this:
expr:
int
Relevant files
shared/prolog/xbgf1.proshared/prolog/xbgf2.proshared/rascal/src/transform/library/Productions.rscshared/xsd/xbgf.xsd
See also
- Eliminate is a part of XBGF