[SERVER-41414] Have stdx::variant unconditionally implemented by mpark Created: 30/May/19  Updated: 07/Nov/23  Resolved: 31/May/19

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 4.1.14

Type: New Feature Priority: Major - P3
Reporter: Jacob Evans Assignee: Jacob Evans
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-82900 Remove variant.h and stdx::variant alias Closed
Backwards Compatibility: Fully Compatible
Participants:

 Description   

mpark's excellent variant implementation is conditionally used by us if we type stdx::variant and <variant> is not present. Since this is never the case on any current compiler, we are always using an inferior implementation. Furthermore std::visit is not implemented by one of our current compilers, leading to <variant> being incomplete but chosen over mpark anyway.

We should remove the ifdef conditions on mpark::variant so it is always chosen as the implementation of stdx::variant. The standard library version is now always available through std:: anyway.



 Comments   
Comment by Githook User [ 31/May/19 ]

Author:

{'name': 'Jacob Evans', 'email': 'jacob.evans@10gen.com'}

Message: SERVER-41414: Have stdx::variant unconditionally implemented by mpark
Branch: master
https://github.com/mongodb/mongo/commit/0d36b26ad2f8041f2fcf14ee199b97ee50d7e013

Comment by Jacob Evans [ 30/May/19 ]

Code review URL: https://mongodbcr.appspot.com/467670003/

Generated at Thu Feb 08 04:57:39 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.