Actions
Bug #4675
closedsaxon:timestamp sample code found in the documentation fails
Start date:
2020-08-10
Due date:
% Done:
100%
Estimated time:
Legacy ID:
Applies to branch:
10, 9.9
Fix Committed on Branch:
10, 9.9
Fixed in Maintenance Release:
Platforms:
Description
The timestamp sample found here: http://www.saxonica.com/documentation/index.html#!functions/saxon/timestamp
Sample:
<xsl:variable name="start" select="saxon:timestamp()" as="xs:dateTimeStamp"/>
<!-- force evaluation -->
<xsl:if test="$start eq xs:dateTime('1900-01-01T00:00:00')"><x/></xsl:if>
<!-- code under test goes here -->
<xsl:message expand-text="yes">Execution time: {(saxon:timestamp() - $start) div xs:duration('PT0.001')}ms </xsl:message>
Fails with the following error:
Evaluation will always throw a dynamic error: Invalid duration value 'PT0.001' (missing unit letter at end)
Updated by Debbie Lockett over 3 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
- Fix Committed on Branch 10, 9.9 added
Documentation fix committed to 9.9 and 10 branches, and updated online (XML and HTML versions).
Please register to edit this issue
Actions