[Xpath-ng] List constructor syntax
David Rosenborg
darolst at pantor.com
Thu Dec 5 04:44:55 MST 2002
David Carlisle wrote:
>
> foo="{validate{$bar}}"
>
> The obvious solution there (over in xpath2 land)is to make validate a
> normal function, it is as far as I know the only use of {} in Xpath (as
> opposed to query) and just sticks out like a sore thumb.
Yes, but the validate expression and the expressions where I think braces
could be used, like in node constructors are unlikely to appear as the
direct child of an AVT in practice. foo="{element bar {'baz'}}"
wouldn't make much sense. And for those insisting on doing this,
they could get away with an extra space as in foo="{element bar {'baz'} }"
or an extra pair of parenthesis foo="{(element bar {'baz'})}". Not
a perfect solution, but I think braces will prove too valuable to exclude
from the language in general in the long run. We just have to be
careful to where we introduce them.
Cheers,
David
More information about the Xpath-ng
mailing list