Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-4357

Missing appender for uint64_t in BSONObjBuilder

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 2.1.0
    • Affects Version/s: None
    • Component/s: Internal Client
    • Environment:
      Linux x86_64 / g++
    • Minor Change
    • Linux

      Compilation fails on BSONObjBuilder when one of the arguments is of uint64_t type.

      Example:

      uint64_t val;
      BSONObj b = BSON("key" << val);

      Error produced:

      <...>/mongo/client/../util/net/../../db/../bson/bson-inl.h: In member function 'mongo::BSONObjBuilder& mongo::BSONObjBuilderValueStream::operator<<(T) [with T = long unsigned int]':
      <...>/mongo/client/../util/net/../../db/../bson/bson-inl.h:341: error: call of overloaded 'append(const char*&, long unsigned int&)' is ambiguous

            Assignee:
            mathias@mongodb.com Mathias Stearn
            Reporter:
            shmerl Hillel Lubman
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: