map::emplace is not available on g++ 4.7 and 4.6, use insert instead