This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: MSXML v. Saxon - whose bug?


> The following XML and XSL produces one more output element in 
> Saxon 5.4
> than in MSXML3 July download - listings follow (with some removeal of
> blank lines):
>   <xsl:template match="status" />
>   <xsl:template match="itemStatus/status" />
>   <xsl:template match="itemStatus/*">
>     <attribute name="{name(.)}"><xsl:value-of
> select="text()"/></attribute>
>   </xsl:template>
> 
The second and third template rules above both match the <status> element.
This is technically an error. The processor is allowed to recover from this
error by choosing the template rule that comes last in the stylesheet, which
is what Saxon is doing. MSXML appears to be applying the itemStatus/status
rule, which I think is definitely incorrect.

But really you should be giving these rules explicit priorities.

Mike Kay 


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]