Project

Profile

Help

Bug #4861

closed

type-available('xs:dateTimeStamp') is true on XSD 1.0

Added by Air Quick over 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Low
Assignee:
Category:
XSLT conformance
Sprint/Milestone:
-
Start date:
2020-12-22
Due date:
% Done:

100%

Estimated time:
Legacy ID:
Applies to branch:
10, trunk
Fix Committed on Branch:
10, trunk
Fixed in Maintenance Release:
Platforms:

Description

--xsd-version:1.0 disables xs:dateTimeStamp:

$ cat use.xsl 
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="3.0" xmlns:xs="http://www.w3.org/2001/XMLSchema"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:output method="text" />
  <xsl:template name="xsl:initial-template">
    <xsl:sequence select="'abc' instance of xs:dateTimeStamp" />
  </xsl:template>
</xsl:stylesheet>
$ java -jar saxon-he-10.3.jar -it -xsl:use.xsl --xsd-version:1.0
Error near {...' instance of xs:dateTimeSt...} at char 18 in xsl:sequence/@select on line 6 column 65 of use.xsl:
  XPST0080  The built-in atomic type xs:dateTimeStamp is not recognized unless XSD 1.1 is enabled
Errors were reported during stylesheet compilation

still type-available('xs:dateTimeStamp') is true:

$ cat type-available.xsl 
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="3.0" xmlns:xs="http://www.w3.org/2001/XMLSchema"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:output method="text" />
  <xsl:template name="xsl:initial-template">
    <xsl:sequence select="type-available('xs:dateTimeStamp')" />
  </xsl:template>
</xsl:stylesheet>
$ java -jar saxon-he-10.3.jar -it -xsl:type-available.xsl --xsd-version:1.0
true

Please register to edit this issue

Also available in: Atom PDF