RE: Runtime semantics of p:try

> "Toman_Vojtech@emc.com" <Toman_Vojtech@emc.com> writes:
> > Now, ehm, I just found another passage in the spec that 
> seems to have
> > the same problem (Section 2, Pipeline Concepts):
> >
> > "A pipeline must behave as if it evaluated each step each time it
> > occurs."
> >
> > Again, the sentence does not take multi-container steps 
> into account.
> 
> How so? The step, be it p:identity or p:choose, is evaluated each time
> it occurs. In the case of p:choose, not all of the subpipelines are
> evaluated each time, but we don't claim they have to be. Or am I
> confused again?

It probably just boils down to what "to occur" means. I understood it as
"to simply appear somewhere in the pipeline". In that context, the
following pipeline would be problematic:

<p:choose>
  <p:when test="false()">
    <p:identity name="id1"/>
  </p:when>
  <p:otherwise>
    <p:identity name="id2"/>
  </p:otherwise>
</p:choose>

The step "id1" occurs in the pipeline, but the processor can never
evaluate it.


But if "to occur" relates to encountering the step while evaluating the
pipeline, then the spec is right.

Regards,
Vojtech

Received on Wednesday, 7 October 2009 12:03:50 UTC