map/unordered_map with non-movable, default constructible value type
问题 Update : It appears, in 23.5.4.3 here that the m[1] version should be valid Update2 : m[1] is working with gcc4.9.1 specifically, std::mutex . Let's say I want to have a std::unordered_map<int, std::mutex> . Is this possible? I can't seem to add a mutex to the map without triggering an error on a deleted copy constructor at some level, either of the mutex or of the intern std::pair holding the mutex. m.emplace(1); m.emplace(1, {}); m[1]; all fail to compile. All I really want is for the mutex