Uploaded image for project: 'Go Driver'
  1. Go Driver
  2. GODRIVER-1921

Decimal128 isZero

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Major - P3 Major - P3
    • None
    • 1.5.0
    • BSON
    • None
    • Not Needed

    Description

      ```

      import github.com/rs/zerolog/log

      p := primitive.NewDecimal128(0, 0)

      log.Debug().
      Str("testData.TestPrimitiveDecimal128", testData.TestPrimitiveDecimal128.String()).
      Str("p", p.String()).
      Str("mongo.DecimalZero", Decimal128Zero.String()).
      Bool("p.IsZero", p.IsZero()).
      Bool("mongo.DecimalZero.IsZero", Decimal128Zero.IsZero()).
      Msg("init")

      ```

      Running this code gives me the following:

      Attachments

        Activity

          People

            benji.rewis@mongodb.com Benji Rewis (Inactive)
            sweetat@withevo.com Swee Tat Lim
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: