[Bug 7350] [XPath 2.1] Higher Order Functions Need Sugar

http://www.w3.org/Bugs/Public/show_bug.cgi?id=7350





--- Comment #5 from John Snelson <john.snelson@oracle.com>  2009-08-19 23:16:39 ---
For those that like to see the EBNF, these are the changes I was suggesting in
comment #4:

LiteralFunctionItem ::= QName "#" IntegerLiteral? /* ws:explicit */

DynamicFunctionInvocation ::= FunctionItem "(" ArgOrNotPovided
  ("," ArgOrNotProvided)*)? ")"

FunctionItem ::= FilterExpr

ArgOrNotProvided ::= ExprSingle | "?"

The explicit whitespace flag has been added to the literal function item
production to enable easier parsing, especially given the newly optional arity
integer.

Note that using the "?" partial apply syntax provides no way to partially apply
an argument to a 1-arity function to turn it into a 0-arity function. I don't
see this as a big drawback, but it's worth pointing out.


-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

Received on Wednesday, 19 August 2009 23:16:51 UTC