Uploaded image for project: 'Compass '
  1. Compass
  2. COMPASS-3667

decimal128: comparing NaN and Infinity with other values of dec128

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Won't Do
    • Icon: Major - P3 Major - P3
    • No version
    • None
    • None
    • None
    • 2
    • Not Needed

    Description

      Need to add a check to compare values of NaNs and Infinities with other values of Decimal128. Current implementation will work when you compare -NaN and NaN for example, but not +NaN and 1.24E+4.

       

      For reference, check the c-sharp implementation: https://github.com/mongodb/mongo-csharp-driver/blob/v2.8.1/src/MongoDB.Bson/ObjectModel/Decimal128.cs#L1901

      or ideally the java implementation which has the clearest overview imo: https://github.com/mongodb/mongo-java-driver/blob/r3.10.1/bson/src/main/org/bson/types/Decimal128.java#L387-L407

      Attachments

        Activity

          People

            Unassigned Unassigned
            irina.shestak@mongodb.com Irina Shestak (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: