On Thu, 22 Jul 2021 23:20:37 +0100, Pete Cordell wrote:
If you're not interested in the new syntax being a subset of XML and
you still want namespaces, you'll want to consider an alternative way
of mapping namespace prefixes to namespaces so that the mapping is
available BEFORE it is required. Currently the mapping mechanism
requires a fair bit of pre-fetching and caching which is sub-optimal.
Something like the following might work:
<:and http://www.whatever.com/:>
<and:harry />
Why? That still separates :and from and:, so if you start parsing on
the <and:harry /> line, you're busted. And why use a non-default prefix
for an element?
<harry xmlns="http://www.whatever.com">
And if the have the following and want to extract sally you are still
busted: