Commit f4902ece by Ben Pritchard

Use emplace for casting to map

parent 52f4c3ae
......@@ -72,7 +72,7 @@ template <typename Type, typename Key, typename Value> struct map_caster {
if (!kconv.load(it.first.ptr(), convert) ||
!vconv.load(it.second.ptr(), convert))
return false;
value[(Key) kconv] = (Value) vconv;
value.emplace((Key) kconv, (Value) vconv);
}
return true;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment