Throwing ExtensionDBException uses non-standard C++

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Query Integration
    • ALL
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Newer versions of Visual Studio outputs this warning (that gets treated as error). You will run into this at some point when we upgrade the compiler.

      src/mongo/db/extension/sdk/extension_status.cpp(74,5): error C2220: the following warning is treated as an error
          throw ExtensionDBException(std::move(status));
          ^
      src/mongo/db/extension/sdk/extension_status.cpp(74,5): warning C5272: throwing an object of non-copyable type 'mongo::extension::sdk::ExtensionDBException' is non-standard. If a copy is needed at runtime it will be made as if by memcpy.
      
      Microsoft (R) C/C++ Optimizing Compiler Version 19.40.33811 for x64
      Copyright (C) Microsoft Corporation.  All rights reserved.
      

      Reproduced with Visual Studio 2022 17.10.3

            Assignee:
            Unassigned
            Reporter:
            Henrik Edin
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: