Boost bimap fails to compile with gcc 10, c++20. Looking for temporary fix
问题 With gcc 10.1 and boost 1.73.0, the following code #include <boost/bimap.hpp> int main() { boost::bimap<int, int> lookup; } fails to compile with flags -O2 --std=c++20 , but will succeed with flags -O2 -std=c++17 (verified with compiler explorer). This is possibly related to the following issue: https://github.com/boostorg/bimap/pull/15 (deprecated std::allocator<void> ) Is there some workaround I can use for now to get this code to successfully compile with --std=c++20 ? 回答1: The reason