-
Key: DMN12-78
-
Status: closed Implementation work Blocked
-
Source: Red Hat Inc ( Edson Tirelli)
-
Summary:
Page 109 of the specification, 3rd bullet, states:
“A name start (grammar rule 28) SHALL NOT be a language keyword. (Language keywords are enclosed in double quotes in the grammar rules, for example, "and", "or", "true", "false".)"
The specification defines a function invocation on page 108, rule 40, as:
function invocation = expression , parameters ;
The list of built-in functions on page 134 lists both functions “and(…)” and “or(...)” as built in functions, but from the grammar rules mentioned above, it is clear that “and”, is not a valid "expression", and so “and(…)” is also not a valid function invocation.
The same is true for “or(...)”.
Either the functions need to be renamed to use valid identifiers (i.e., identifiers that do not start with a keyword) or the grammar has to be changed to allow for this special case. My personal preference is to rename the built in functions to something like “list and(...)” and “list or(...)”.
-
Reported: DMN 1.1 — Tue, 23 Aug 2016 01:25 GMT
-
Disposition: Resolved — DMN 1.2
-
Disposition Summary:
rename 'and' to 'all' and 'or' to 'any'
see revised text
Argument for Backward Compatibility
Normally, a change of name of built-in function would be an incompatible change. However, this part of the 1.1 spec proved impossible to implement, because the name of a built-in cannot be a language keyword. I.e., nothing to be compatible with here. -
Updated: Wed, 3 Oct 2018 14:17 GMT
DMN12 — Impossible to invoke functions and() and or()
- Key: DMN12-78
- OMG Task Force: Decision Modeling and Notation 1.2 RTF