Parameterless function call
haskellcamargo opened this issue · comments
Marcelo Camargo commented
Parameterless function calls generate an error.
`"SELECT X(Y(Z())) AS TOTAL FROM STJ TBL"``
Dies in Unexpected 'RIGHT_PAREN'
, while
`"SELECT X(Y(Z)) AS TOTAL FROM STJ TBL"``
Works fine.
I'll try to fix it in the Jison grammar and submit a pull-request.
Marcelo Camargo commented
Please, note that there are some ambiguities in the current defined grammar. The current version of Jison gives us warnings about them.
But this can be trivially solved by adding a new production to UserFunction
:
o "LITERAL LEFT_PAREN RIGHT_PAREN", -> new FunctionValue($1, [], true)