[CXX-2350] Evaluate migration to more recent C++ standards Created: 17/Aug/21  Updated: 02/Jan/24

Status: Backlog
Project: C++ Driver
Component/s: Build, Implementation
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Unknown
Reporter: Jesse Williamson (Inactive) Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: size-medium
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
depends on CXX-2284 Append platform data to handshake Closed
Related
is related to CXX-1306 Require at least C++17 Closed
Epic Link: CXX usability improvements
Quarter: FY25Q3

 Description   

Currently, the C++ Driver code mandates the ten year old C+11 standard. It may be worth evaluating whether a more recent standard, such as C17, or even the current C+20 standard should be adopted.

There have been numerous improvements to both the language and standard library introduced in the decade since C++11. Many of these make the language safer, more productive to use, or more performant.

Additionally, we current maintain a support library (mongodb::cxx) that provides C++17 library compatibility; much of this support could be moved to the standard library.

By adopting newer versions of C++, we allow to greater flexibility and idiomatic usage in our client, enhancing its usability and performance, but also increasing confidence in its design and implementation.

During this process, barriers to adoption should be understood and weighed against benefits. A typical barrier is that a high percentage of users may be themselves limited to using C++11.

Note: it is possible to provide versioned APIs with inlined namespaces and other techniques, although this does not provide ABI compatibility.


Generated at Wed Feb 07 22:05:39 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.