W3C home > Mailing lists > Public > xproc-dev@w3.org > September 2011

Calabash 0.9.33: bug with XPath variables

From: Romain Deltour <rdeltour@gmail.com>
Date: Thu, 1 Sep 2011 20:40:46 +0200
Message-Id: <1C085C52-E251-4EF8-A090-20A445960AD2@gmail.com>
To: XProc Dev <xproc-dev@w3.org>
FYI it seems Calabash 0.9.33 introduced a new bug when evaluating  
XPath expressions. It fails to recognize a variable when an operator  
(e.g. '=') is stuck right after the variable name with no space.

For instance it raises an NPE with the following pipeline:

<p:declare-step xmlns:p="http://www.w3.org/ns/xproc" version="1.0">

     <p:output port="result"/>

     <p:variable name="var" select="'value'"/>

     <p:add-attribute attribute-name="test" match="/*">
         <p:with-option name="attribute-value" select="$var='value'"/>
         <p:input port="source">
             <p:inline>
                 <doc/>
             </p:inline>
         </p:input>
     </p:add-attribute>

</p:declare-step>

It works as expected when the XPath expression in the p:with-option/ 
@select is "$var = 'value'".

I've added the issue to the tracker:
http://code.google.com/p/xmlcalabash/issues/detail?id=152


Romain.
Received on Thursday, 1 September 2011 18:41:31 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 1 September 2011 18:41:31 GMT