W3C home > Mailing lists > Public > xproc-dev@w3.org > May 2009

RE: unbound option bug in Calabash, I think

From: <Toman_Vojtech@emc.com>
Date: Fri, 15 May 2009 08:34:21 -0400
Message-ID: <6E216CCE0679B5489A61125D0EFEC7870F953AF9@CORPUSMX10A.corp.emc.com>
To: <xproc-dev@w3.org>
> 
> No, I don't think so. That paragraph is supposed to tell you that the
> select expressions aren't evaluated when the declaration is
> encountered, they're evaluated when a step of that type is used.
> 
> So, if you had a library that contained:
> 
>   <p:declare-step type="my:extension">
>     <p:option name="random" select="java:random()"/>
>   </p:declare-step>
> 
> and a pipeline that contained:
> 
>   <my:extension/>
>   <my:extension/>
> 
> you would not expect each call to my:extension to receive the same
> value for the random option 
> (http://twitter.com/codinghorror/status/1803680004
> notwithstanding), one computed when the processor read the
> declaration.

I understand that. But that paragraph in 5.7.2 seems to suggest that it
goes even further:

<p:pipeline xmlns:p="http://www.w3.org/ns/xproc">
  <!-- everything fine because select is not evaluated here -->
  <p:option name="myopt" select="$myopt2"/>
  <p:option name="myopt2" select="'foo'"/>
  <p:count>
    <!-- here I get err:XD0026 because myopt refers to myopt2
         (which does not precede myopt in the step decl -->
    <p:with-option name="limit" select="... $myopt ..."/>
  </p:count>
</p:pipeline>

Or did I just went too far? (...please say so)

> I think (in addition to clarifying the paragraph that bot you and
> Vojtech quoted), we should say either that the $notUsed expression
> MUST or MAY produce an error. In the interest of interoperability and
> simplicity, I favor MUST, but I'm not going to lie down in the road
> about it.

+1 to MUST

Regards,
Vojtech
Received on Friday, 15 May 2009 12:35:16 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 15 May 2009 12:35:16 GMT