Nullability |
Top Previous Next |
Grammar tests > Nullability
The warning
"X" is nullable
appears, if the production "X" matches an empty text. For example "X" may be defined by:
X ::= "la" *
This rule will recognize a text like "la la la", but also the empty text "" matches, because the '*"-repeat matches null repeats. In contrast, the production
X ::= "la" +
is not nullable.
This warning can be a hint, that a nullable alternative was created inadvertently.
Productions, which only consist of semantic actions, in principle, are nullable too. However a warning will not be created in this case, because such a rule cannot lead to a wrong recognition, but can be uses as helping function.
The creation of this warning can be suppressed by an according checkbox in the project options.
|
This page belongs to the TextTransformer Documentation |
Home Content German |