RE: [XSLT2] 11.1.4 ns alias: implementation-dependent prefixes

Mike Kay wrote:

> I think we need to retain the principle that
> prefixes are not held in element and attribute nodes, only in namespace
> nodes, and this constrains the solution.
> 
> In fact, I think the example we have added to XSLT 2.0 is inconsistent with
> what the specification says. Suppose you write:
> 
> <xsl:stylesheet
>   version="2.0"
>   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
>   xmlns:axsl="file://namespace.alias">
> 
> <xsl:namespace-alias stylesheet-prefix="axsl" result-prefix="xsl"/>
> 
> <xsl:template match="/">
>   <axsl:template match="xsl:template"/>
> </xsl:template>
> 
> </xsl:stylesheet>
> 
> Then the axsl:template element in the stylesheet has a namespace node
> (axsl=file://namespace.alias), and the effect of the rules as written is
> that the result tree must therefore have a namespace node
> (axsl=http://www.w3.org/1999/XSL/Transform). Therefore, the namespace
> declaration xmlns:axsl="http://www.w3.org/1999/XSL/Transform" must appear in
> the serialized result. 

It seems, things are a little bit complicated with the null namespace.
If the target namespace of a namespace-alias is the null namespace
(#default in result-prefix denotes the null namespace) then of course
there's no namespace node (axsl="") since this conflicts with the namespaces
recommendation.

Oliver


/-------------------------------------------------------------------\
|  ob|do        Dipl.Inf. Oliver Becker                             |
|  --+--        E-Mail: obecker@informatik.hu-berlin.de             |
|  op|qo        WWW:    http://www.informatik.hu-berlin.de/~obecker |
\-------------------------------------------------------------------/

Received on Tuesday, 2 September 2003 09:54:12 UTC