[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

[xsl] XSLT 3.0: Conflicting text describing


Subject: [xsl] XSLT 3.0: Conflicting text describing <xsl:mode>
From: "Dimitre Novatchev dnovatchev@xxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
Date: Wed, 24 Dec 2014 17:58:21 -0000

 In the 2nd Last Call of the XSLT 3.0 specification, section "6.6.1
Declaring modes" provides the syntax of an <xsl:mode> declaration as:

<!-- Category: declaration -->
< xsl:mode
  name? = eqname
  streamable? = boolean
  on-no-match? = "deep-copy" | "shallow-copy" | "deep-skip" |
"shallow-skip" | "text-only-copy" | "fail"
  on-multiple-match? = "use-last" | "fail"
  warning-on-no-match? = boolean
  warning-on-multiple-match? = boolean
  typed? = boolean | "strict" | "lax" | "unspecified"
  visibility? = "public" | "private" | "final" />


As we clearly see, there is no provision that an <xsl:mode> can have
any content (such as children elements).

However, at the end of the section we read:

"The above rules apply both to the attributes (other than name) of the
xsl:mode element itself, and to the attributes of the contained
xsl:context-item element if present."

So, it seems that an <xsl:mode> can have as a child an
<xsl:context-item> element.

This clearly is in conflict with the syntax above, and the fact that
an "xsl:mode" can have content/children is not mentioned anywhere in
the whole section "6.6 Modes".

One could wonder which is right: the syntax definition above (no
content), or the sentence that implies that an <xsl:mode> can have an
<xsl:context-item> element as child.

If the latter is true, then probably there might be yet other children
elements of <xsl:mode> -- also unmentioned?

It seems that in its current version, the text defining <xsl:mode> is
incomplete and doesn't provide important information about the
structure/content of this XSLT declaration.

Hope that this observation would be reflected in a future, needed correction.

-- 
Cheers,
Dimitre Novatchev


Current Thread
Keywords