Skip to content

bug: PrimitiveLiteral and Literal should not be Ord. #378

@liurenjie1024

Description

@liurenjie1024

In rust, Ord means total order, while PartiarOrd mean partital order. Currently we have derived Ord for both PrimitiveLiteral and Literal, which is incorrect. How could we compare Struct with Map, or Date with String? We should do following changes:

  1. Remove PartialOrd, Ord for both Literal.
  2. Remove Ord for PrimitiveLiteral. I think we should also remove PartialOrd for PrimitiveLiteral, which misses type information for decimal.
  3. Implement PartialOrd for Datum.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    Status

    Done

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions