[Bug 1461] New: Casting from YMD to DTD and vice versa

http://www.w3.org/Bugs/Public/show_bug.cgi?id=1461

           Summary: Casting from YMD to DTD and vice versa
           Product: XPath / XQuery / XSLT
           Version: Last Call drafts
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Functions and Operators
        AssignedTo: ashok.malhotra@oracle.com
        ReportedBy: mike@saxonica.com
         QAContact: public-qt-comments@w3.org


It is possible to cast from an xs:duration to an xdt:dayTimeDuration. The
prinicile of type Substitutability therefore demands that it should be possible
to cast from any subtype of xs:duration to an xdt:dayTimeDuration. However, the
casting table in F+O section 17 says that casting from xdt:yearMonthDuration to
xdt:dayTimeDuration is disallowed.

In my view this cast should be allowed and should return a zero length duration.

The same also applies of course to the inverse cast.

(Problem revealed by running the test suite.)

Received on Tuesday, 17 May 2005 17:03:18 UTC