cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vadim Gritsenko" <vadim.gritse...@verizon.net>
Subject Found bug in XSLTC
Date Sat, 13 Jul 2002 15:28:04 GMT
Hi all,

Found a bug in XSLTC, version from
http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-cocoon2/lib/core/xsltc.
jar?rev=HEAD&content-type=text/plain.

Here is XSLT reproducing the bug:
----------8<----------
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:param name="var">
    <xsl:if test="1 = 1">2</xsl:if>
  </xsl:param>

  <xsl:param name="var2" select="string($var)"/>

  <xsl:template match="/">
    Value of var: <xsl:value-of select="$var"/>
    var is greater then 3: <xsl:value-of select="$var &gt; 3"/>
    var is less then 3: <xsl:value-of select="$var &lt; 3"/>

    Value of var2: <xsl:value-of select="$var2"/>
    var2 is greater then 3: <xsl:value-of select="$var2 &gt; 3"/>
    var2 is less then 3: <xsl:value-of select="$var2 &lt; 3"/>
  </xsl:template>
</xsl:stylesheet>
----------8<----------


Output:
----------8<----------
    Value of var: 2
    var is greater then 3: false
    var is less then 3: false

    Value of var2: 2
    var2 is greater then 3: false
    var2 is less then 3: true
----------8<----------

All other XSLT processors (Xalan, SAXON) produce output:
----------8<----------
    Value of var: 2
    var is greater then 3: false
    var is less then 3: true

    Value of var2: 2
    var2 is greater then 3: false
    var2 is less then 3: true
----------8<----------


Regards,
Vadim



---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Mime
View raw message