Maybe I'm being stupid, but I don't see what the problem with this code is. I'm starting to resort to doubting my tools. I'm using Clang (C++11), and its libc++. If it's my fault, I apologise and thank in advance whoever points out my stupidity, but if it's not, maybe this is a deeper issue..
std::map<int, bool> map_;
map_.insert(std::make_pair<int, bool>(5, true)); //Use a literal, compiles OK
int x = 5;
map_.insert(std::make_pair<int, bool>(x, true)); //Use a local of same type, compile error: 'no known conversion from 'int' to 'int &&' for 1st argument'