Re: p:input doppelgangers

/ Alessandro Vernet <avernet@orbeon.com> was heard to say:
| On 7/4/07, Norman Walsh <ndw@nwalsh.com> wrote:
|> / ht@inf.ed.ac.uk (Henry S. Thompson) was heard to say:
|> |  p:xpath-context
|> |    (p:empty | p:pipe | p:document | p:inline )?
|> |
|> |    A special case -- exactly one document, or none.  A dynamic error
|> |    if p:empty is used and a 'test' XPath expression appeals to the
|> |    context-node or context-position.
|>
|> Fixed.
|
| And p:empty is accepted? XPath expressions are evaluated in a context,
| and a context node is part of that context. Even if some expressions
| do not use the context node, my understanding is that XPath requires a
| context node to be present. In fact (at least some) XPath libraries
| enforce this by require a context node. So what would the context node
| be when p:empty is used?

It doesn't matter because an expression that refers to the context is
an error if there isn't a context.

It seems to me that requiring a context for an expression like "$foo"
is even more problematic for users than requiring implementors to
deal with not having a context in that case.

                                        Be seeing you,
                                          norm

-- 
Norman Walsh <ndw@nwalsh.com> | If today was a fish, I'd throw it back
http://nwalsh.com/            | in.

Received on Thursday, 5 July 2007 11:45:23 UTC