Andrew Dunstan <andrew@dunslane.net> writes:
> For fear of passing an ill formed fragment of xml to the processor, we
> strip the xml declaration if any and surround what's left with '<x>" and
> '</x>' and prepend '/x' to the supposed xpath. This is just horrible.
I seem to recall having complained about that at the time, but I didn't
(and don't) know enough about xpath to do any better.
> This whole thing is a mess, and I suspect the only fix for now is to
> undo all the mangling of both the xml and the xpath expression.
I don't think we should change the behavior if it's just to arrive at
another less-than-desirable behavior. Whacking semantics around afresh
with each release does not endear us to users. If we know how to fix it
right, great; but if we can't then we should keep compatibility with 8.3
until we can.
regards, tom lane