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 27676 - Typography makes it extremely difficult to find the definition of a built-in template
Summary: Typography makes it extremely difficult to find the definition of a built-in ...
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XSLT 3.0 (show other bugs)
Version: Last Call drafts
Hardware: PC Windows NT
: 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-12-19 19:24 UTC by dnovatchev
Modified: 2015-10-29 09:50 UTC (History)
1 user (show)

See Also:


Attachments

Description dnovatchev 2014-12-19 19:24:34 UTC
In section "6.7.1 Built-in Templates: Text-only Copy" at http://www.w3.org/TR/2014/WD-xslt-30-20141002/#built-in-templates-text-only-copy, we read:

"The built-in template rule for text and attribute nodes returns a text node containing the string value of the context node. It is effectively:

<xsl:template match="text()|@*" mode="M">
  <xsl:value-of select="string(.)"/>
</xsl:template>
Note:

This text node may have a string value that is zero-length.

diff="chg" at="R-bug26751">The built-in template rule atomic values returns a text node containing the value. It is effectively:

<xsl:template match=".[. instance of xs:anyAtomicType]" mode="M">
  <xsl:value-of select="string(.)"/>
</xsl:template>
Note:

This text node may have a string value that is zero-length.

The built-in template rule for processing instructions, comments, and namespace nodes does nothing (it returns the empty sequence)."



It is very difficult to notice that the quoted text actually contains the definitions for two built-in templates, the second being buried inside a Note for the first definition. Also, it seems that the displayed string 'diff="chg" at="R-bug26751">' is the result of accident and this may be the cause of the way the text is displayed (both in Chrome and IE11).

Because of the importance of built-in templates in the language, any reader would expect any built-in template definition to be clearly visible and not hidden among other text. Besides correcting the typography, adding a TOC entry for every built-in template will significantly improve the quality of the document.

Dimitre Novatchev
Comment 1 dnovatchev 2014-12-19 20:23:23 UTC
Also, the sentence: "The built-in template rule atomic values returns a text node containing the value." was probably intended to be: "The built-in template rule *for* atomic values returns a text node containing the value.
Comment 2 Michael Kay 2014-12-21 18:48:39 UTC
Thanks. I have fixed these typos.