- From: Norman Walsh <ndw@nwalsh.com>
- Date: Mon, 21 Jun 2010 10:43:42 -0400
- To: public-xml-processing-model-wg@w3.org
- Message-ID: <m2k4psigyp.fsf@nwalsh.com>
"Toman_Vojtech@emc.com" <Toman_Vojtech@emc.com> writes: > When responding to a question on xproc-dev today > (http://lists.w3.org/Archives/Public/xproc-dev/2010Jun/0041.html), I Sigh. I am so far behind again. > realized that the spec is perhaps a bit unclear about the in-scope > variable bindings that are in scope for p:variable/@select. More > specifically, is the following allowed? > > <p:variable name="x" select="'foo'"/> > <p:variable name="y" select="$x"/> > > If so, where does it follow from? The third paragraph of 5.7.1 says, of p:variable, in part: ...with the addition of bindings for all preceding-sibling p:variable and p:option elements. So I think the example above is pretty clearly allowed. > Based on the xproc-dev discussion, it > looks like Calabash does not support this - but Calumet does. That's news to me; given pipe.xpl: <p:declare-step xmlns:p="http://www.w3.org/ns/xproc" version="1.0"> <p:output port="result"/> <p:variable name="y" select="'foo'"/> <p:variable name="x" select="$y"/> <p:add-attribute match="/*" attribute-name="test"> <p:input port="source"> <p:inline><doc/></p:inline> </p:input> <p:with-option name="attribute-value" select="$x"/> </p:add-attribute> </p:declare-step> I get: $ calabash /projects/src/calabash/pipe.xpl INFO: Running pipeline !1 INFO: Running add-attribute !1.4 <doc test="foo"/> Be seeing you, norm -- Norman Walsh <ndw@nwalsh.com> | "Bother", said Pooh, as he deleted his http://nwalsh.com/ | root directory.
Received on Monday, 21 June 2010 14:44:20 UTC