Closed dbenn closed 1 month ago
The following:
f(n:real) : real { 12.0 } f(4)
yields:
Cannot invoke "org.aavso.tools.vstar.vela.Operation.ordinal()" because the return value of "org.aavso.tools.vstar.vela.AST.getOp()" is null
when 12.0 should be returned.
12.0
4
Note that such literal-only expressions will have been the subject of constant folding so that at execution time, no operator will be present in the AST, which is consistent with the error.
The following:
yields:
when
12.0
should be returned.Notes
4
is passed as an actual parameter, it is not used in the body of the function.