Uploaded image for project: 'Ruby Driver'
  1. Ruby Driver
  2. RUBY-2952

BSON::Decimal128 always compares false with other types

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Unknown
    • Resolution: Won't Do
    • None
    • None
    • BSON
    • None

    Description

      BSON::Decimal128 always compares false with other types:

      irb(main):001:0> BSON::Decimal128.new('1')==1
      => false
      

      This behavior does not match Ruby:

      irb(main):002:0> 1.0==1
      => true
      irb(main):003:0> BigDecimal('1')==1
      => true
      

      I think we should match Ruby behavior in BSON 5.

      Attachments

        Issue Links

          Activity

            People

              neil.shweky@mongodb.com Neil Shweky
              oleg.pudeyev@mongodb.com Oleg Pudeyev (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: