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

Clang 19 compilation failure in bsoncolumnbuilder.h due to call to deleted constructor of TrackingAllocator

    • Type: Icon: Bug Bug
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Server Programmability
    • ALL

      Clang 19 encounters a compilation failure in bsoncolumnbuilder.h. BSONColumnBuilder defines a unary constructor that takes an instance of a templated allocator type, which defaults to a default-constructed instance. Sometimes BSONColumnBuilder instances instantiate the Allocator template with the TrackingAllocator, which explicitly deletes the nullary constructor. As a result, any such instance that attempts to default-construct will fail in compilation.

      It's unclear why Clang 19 uniquely runs into this issue (full compile output will be posted in a comment), but in any case we should tolerate allocator types which are not default-constructible because the C++ standard does not require them to be.

            Assignee:
            Unassigned Unassigned
            Reporter:
            james.bronsted@mongodb.com James Bronsted
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: