[Bug 26330] New: The semantics for the applies-to attribute on accumulators prevents use with non-document initial context items

https://www.w3.org/Bugs/Public/show_bug.cgi?id=26330

            Bug ID: 26330
           Summary: The semantics for the applies-to attribute on
                    accumulators prevents use with non-document initial
                    context items
           Product: XPath / XQuery / XSLT
           Version: Last Call drafts
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XSLT 3.0
          Assignee: mike@saxonica.com
          Reporter: abel.braaksma@xs4all.nl
        QA Contact: public-qt-comments@w3.org

The initial context item for a stylesheet transformation can be set to
something other than a document node. However, the current definition of
accumulators is such that it only applies to nodes that are rooted in a
document node:

Section 18.2.1:
"An accumulator is applicable to a particular document if the pattern supplied
in the applies-to attribute matches the first element node in the document
(typically the outermost element, though the definition allows for document
nodes that have more than one element child). The default value for the
applies-to attribute is applies-to="*", which ensures that the accumulator is
applicable to every document."

I think this definition has two issues:
1) instead of speaking of document nodes, it should (probably) speak of initial
context items.
2) the current default pattern is "*", but this does not trigger the
accumulator for patterns that are not an element and that, potentially, precede
the first element in a document. Perhaps a default pattern of "node()" makes
more sense.

This bug-entry is somewhat related to Bug 26328.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Monday, 14 July 2014 13:18:53 UTC