This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 26268 - [xslt 3.0] Context for xsl:accumulator/@initial-value
Summary: [xslt 3.0] Context for xsl:accumulator/@initial-value
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XSLT 3.0 (show other bugs)
Version: Working drafts
Hardware: PC All
: P2 normal
Target Milestone: ---
Assignee: Michael Kay
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-04 20:57 UTC by Michael Kay
Modified: 2014-07-27 19:53 UTC (History)
0 users

See Also:


Attachments

Description Michael Kay 2014-07-04 20:57:14 UTC
We say that the context for xsl:accumulator/@initial-value is the "same as the context for global variables" (i.e., the global context item).

We also say that if the accumulator is streamable, the initial-value expression must be grounded and motionless.

These statements are contradictory. The expression only needs to be grounded and motionless if it is evaluated with the document node of the streamed document as the focus.

It actually makes more sense to me for the focus to be the document node of the streamed document to which the accumulator applies. For example, the initial value could then be the base URI of that document.
Comment 1 Michael Kay 2014-07-27 19:43:31 UTC
The WG decided that the focus for evaluation of @initial-value should be the root of the streamable "document". There was some discussion of whether streaming only applies to documents; that discussion is ongoing, but as far as this bug is concerned the decision is that the focus is the root, whatever that might be.

With this decision, it makes obvious sense to require the expression to be grounded and motionless.