Scope OID::ourMachine and OID::ourMachineAndPid to oid.cpp rather than class OID

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Done
    • Priority: Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Internal Code
    • None
    • Fully Compatible
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Having these as class statics visible to header consumers has effects when DLL visibility is in play, in particular the "two variables on one line" thing seems to be baffling MSVC in some bizarre way:

      C:\cygwin\home\andrew\Documents\10gen\dev\opt\include\mongo/bson/oid.h(118) : error C2487: 'ourMachineAndPid' : member of dll interface class may not
      be declared with dll interface
      

      These statics are private, so they should just be scoped to OID.cpp rather than to class OID.

      We can either fix this in the server codebase and pick it up in the C++ driver repo, or, if not, the C++ driver codebase will make this change.

            Assignee:
            Unassigned
            Reporter:
            Andrew Morrow (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: