Why did std::allocator lose member types/functions in C++17?
问题 While looking at std::allocator, I see that members: value_type , pointer , const_pointer , reference , const_reference , size_type , difference_type , and rebind have all been deprecated. Allocators will also no longer have the members: address , max_size , construct , or destroy . Why did this happen? Did it have something to do with polymophic allocators? 回答1: If you look at the relevant isocpp paper you can see that the first set you mention is now thought to be better placed in std: