Uploaded image for project: 'Rust Driver'
  1. Rust Driver
  2. RUST-1692

Be consistent about number deserialization

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Unknown Unknown
    • bson-3.0.0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None

      Right now, when deserializing unsigned numbers, the bson crate will check to see if they fit in an i32 or i64 and return an appropriate bson value; however, there's no such check for signed values.  This can lead to confusion, e.g. storing golden values in yaml, which always deserializes numbers as 64-bit, will produce a mixed stream of Bson::Int32 and Bson::Int64 depending on the sign of the values.

            Assignee:
            Unassigned Unassigned
            Reporter:
            abraham.egnor@mongodb.com Abraham Egnor
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: