Thanks to visit codestin.com
Credit goes to github.com

Skip to content

xsd:g{Day,Month,Year,..} should not be promotable to xsd:date (but xsd:date should stay demotable to xsd:g{..}) #393

@liss-h

Description

@liss-h

That the xsd g-types are promotable to xsd:date means that they can be compared with xsd:date.

The comparisons don't really make sense because to be promoted to xsd:date the missing components are filled in from the unix-epoch. The only direction we need is demotion from xsd:date to xsd g types (according to spec).

That the comparision works currently means for example that "1960-02-01"^^xsd:date < "--01"^^xsd:gMonth is true, which may be unexpected.

To facilitate this change we need to change the interfaces for promotion to allow for failure on promotion as well.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions