PLEASE DO NOT REPLY TO THIS MESSAGE. TO FURTHER COMMENT
ON THE STATUS OF THIS BUG PLEASE FOLLOW THE LINK BELOW
AND USE THE ON-LINE APPLICATION. REPLYING TO THIS MESSAGE
DOES NOT UPDATE THE DATABASE, AND SO YOUR COMMENT WILL
BE LOST SOMEWHERE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=3419

*** shadow/3419 Tue Sep  4 13:36:16 2001
--- shadow/3419.tmp.28995       Tue Sep  4 13:36:17 2001
***************
*** 0 ****
--- 1,137 ----
+ +============================================================================+
+ | xsltc fails conf test position31 with incorrect output                     |
+ +----------------------------------------------------------------------------+
+ |        Bug #: 3419                        Product: XalanJ2                 |
+ |       Status: NEW                         Version: CurrentCVS              |
+ |   Resolution:                            Platform: All                     |
+ |     Severity: Normal                   OS/Version: All                     |
+ |     Priority: Other                     Component: org.apache.xalan.xsltc  |
+ +----------------------------------------------------------------------------+
+ |  Assigned To: [EMAIL PROTECTED]                                     |
+ |  Reported By: [EMAIL PROTECTED]                                          |
+ |      CC list: Cc:                                                          |
+ +----------------------------------------------------------------------------+
+ |          URL:                                                              |
+ +============================================================================+
+ |                              DESCRIPTION                                   |
+ Expected Output (Saxon, XT, and Xalan agree)
+ ---------------
+ <?xml version="1.0" encoding="UTF-8"?>
+ <out>
+   Group: 1
+      left front bracket
+      momentary button
+      toggle button
+      source select dial
+   Group: 2
+      power switch button
+      main panel light
+      selector light
+   Group: 1
+      right front bracket
+   Group: 2
+      top inner bracket
+   Group: 1
+      output select dial
+   Group: 3
+      frequency dial
+      voltage dial
+   Group: 1
+      power light
+   Group: 2
+      safety light
+ </out>
+ 
+ 
+ Obtained Output
+ ---------------
+ <?xml version="1.0" encoding="utf-8" ?>
+ <out>
+   Group: 1
+      left front bracket
+      momentary button
+      toggle button
+      source select dial
+   Group: 2
+      power switch button
+   Group: 2
+      main panel light
+   Group: 2
+      selector light
+      right front bracket
+   Group: 2
+      top inner bracket
+      output select dial
+   Group: 3
+      frequency dial
+   Group: 3
+      voltage dial
+      power light
+   Group: 2
+      safety light
+ </out>
+ 
+ position31.xsl
+ --------------
+ <?xml version="1.0"?>
+ <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version="1.0">
+ 
+   <!-- FileName: position31 -->
+   <!-- Document: http://www.w3.org/TR/xpath -->
+   <!-- DocVersion: 19991116 -->
+   <!-- Section: 4.1 -->
+   <!-- Creator: David Marston -->
+   <!-- Purpose: Test of position() with a sibling axis. -->
+ 
+ <xsl:template match="items">
+   <out>
+     <xsl:apply-templates/>
+   </out>
+ </xsl:template>
+ 
+ <xsl:template match="sfdhd">
+   <xsl:text>Pos</xsl:text><xsl:value-of select="position()"/><xsl:text>
+ G</xsl:text><xsl:value-of select="@group"/><xsl:text>- </xsl:text><xsl:value-of
+ select="."/>
+ </xsl:template>
+ 
+ <xsl:template match="bracket|button|dial|light">
+   <xsl:choose>
+     <xsl:when test="position()=2"><!-- Have to skip interstitial text -->
+       <xsl:text>Group: </xsl:text><xsl:value-of select="@group"/><xsl:text>
+      </xsl:text><xsl:value-of select="."/><xsl:text> </xsl:text><xsl:value-of
+ select="name(.)"/>
+     </xsl:when>
+     <xsl:when test="@group != preceding-sibling::*[1]/@group">
+       <xsl:text>Group: </xsl:text><xsl:value-of select="@group"/><xsl:text>
+      </xsl:text><xsl:value-of select="."/><xsl:text> </xsl:text><xsl:value-of
+ select="name(.)"/>
+     </xsl:when>
+     <xsl:otherwise>
+       <xsl:text>   </xsl:text><xsl:value-of select="."/><xsl:text>
+ </xsl:text><xsl:value-of select="name(.)"/>
+     </xsl:otherwise>
+   </xsl:choose>
+ </xsl:template>
+ 
+ </xsl:stylesheet>
+ 
+ position31.xml
+ --------------
+ <?xml version="1.0"?> 
+ <items>
+   <bracket group="1">left front</bracket>
+   <button group="1">momentary</button>
+   <button group="1">toggle</button>
+   <dial group="1">source select</dial>
+   <button group="2">power switch</button>
+   <light group="2">main panel</light>
+   <light group="2">selector</light>
+   <bracket group="1">right front</bracket>
+   <bracket group="2">top inner</bracket>
+   <dial group="1">output select</dial>
+   <dial group="3">frequency</dial>
+   <dial group="3">voltage</dial>
+   <light group="1">power</light>
+   <light group="2">safety</light>
+ </items>

Reply via email to