fix: don't use default ctor when converting to map

This commit is contained in:
ToruNiina
2020-03-30 15:02:26 +09:00
parent 55a738c11f
commit 79594709fe

View File

@@ -419,7 +419,7 @@ get(const basic_value<C, M, V>& v)
T map;
for(const auto& kv : v.as_table())
{
map[key_type(kv.first)] = ::toml::get<mapped_type>(kv.second);
map.emplace(key_type(kv.first), get<mapped_type>(kv.second));
}
return map;
}