diff --git a/include/boost/unordered/unordered_flat_map.hpp b/include/boost/unordered/unordered_flat_map.hpp index 13ad9c90..04bbc55c 100644 --- a/include/boost/unordered/unordered_flat_map.hpp +++ b/include/boost/unordered/unordered_flat_map.hpp @@ -60,6 +60,23 @@ namespace boost { return {std::move(const_cast(x.first)), std::move(const_cast(x.second))}; } + + template + static void construct(A& al, storage_type* p, moved_type&& x) + { + boost::allocator_construct(al, p, std::move(x)); + } + + template + static void construct(A& al, storage_type* p, Args&&... args) + { + boost::allocator_construct(al, p, std::forward(args)...); + } + + template static void destroy(A& al, storage_type* p) noexcept + { + boost::allocator_destroy(al, p); + } }; using table_type = detail::foa::table + static void construct(A& al, storage_type* p, Key&& x) + { + boost::allocator_construct(al, p, std::move(x)); + } + + template + static void construct(A& al, storage_type* p, Args&&... args) + { + boost::allocator_construct(al, p, std::forward(args)...); + } + + template static void destroy(A& al, storage_type* p) noexcept + { + boost::allocator_destroy(al, p); + } }; using table_type = detail::foa::table