Subject: RE: MSXML v. Saxon - whose bug? From: Andrew Kimball <akimball@xxxxxxxxxxxxx> Date: Wed, 13 Sep 2000 10:53:22 -0700 |
Mike, I agree that explicit priorities should be used here in order to guarantee portability. However, it is Saxon that is applying the itemStatus/status rule, not MSXML. From Francis' mail: =========== SAXON =========== D:\bugs\333a>\xmlschema\saxon t.xml t.xsl Cannot find ParserManager.properties - using built-in parser <?xml version="1.0" encoding="utf-8"?> <header> <status>REFER</status> <attribute name="applicationId">CCUK000000000604</attribute> </header> =========== MSXML =========== D:\bugs\333a>\xmlschema\xslproc t.xml t.xsl <?xml version="1.0" encoding="UTF-16"?> <header> <status>REFER</status> <attribute name="status">REFER</attribute> <attribute name="applicationId">CCUK000000000604</attribute> </header> MSXML is printing out the extra <attribute/> element, while Saxon is not. That implies that MSXML is applying the itemStatus/* rule, while Saxon is applying the itemStatus/status rule. By your analysis, it is MSXML that is correct, not Saxon. Am I missing something?? ~Andy Kimball MSXSL Dev -----Original Message----- From: Kay Michael [mailto:Michael.Kay@xxxxxxx] Sent: Wednesday, September 13, 2000 6:56 AM To: 'xsl-list@xxxxxxxxxxxxxxxx' Subject: 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 XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: MSXML v. Saxon - whose bug?, Kay Michael | Thread | RE: MSXML v. Saxon - whose bug?, Andrew Kimball |
RE: Calling 'transformNode' inside , Krishnamurthy, Rama | Date | RE: MSXML v. Saxon - whose bug?, Andrew Kimball |
Month |