summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Turbov <i.zaufi@gmail.com>2024-08-13 18:35:40 (GMT)
committerAlex Turbov <i.zaufi@gmail.com>2024-08-13 21:37:38 (GMT)
commit503a73b1832dde9685a44c2ee9cc904e39aeaee4 (patch)
treeb84499f0929dac28c5d2ff8a693f6e099af6b8c5
parente7dcd51a61f43ca476c62242969094e629363a37 (diff)
downloadCMake-503a73b1832dde9685a44c2ee9cc904e39aeaee4.zip
CMake-503a73b1832dde9685a44c2ee9cc904e39aeaee4.tar.gz
CMake-503a73b1832dde9685a44c2ee9cc904e39aeaee4.tar.bz2
cmJSONHelpers.h: Use `map::emplace()` instead of `operator[]`
-rw-r--r--Source/cmJSONHelpers.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/cmJSONHelpers.h b/Source/cmJSONHelpers.h
index fe5dca5..b35825d 100644
--- a/Source/cmJSONHelpers.h
+++ b/Source/cmJSONHelpers.h
@@ -348,7 +348,7 @@ struct cmJSONHelperBuilder
if (!func(t, &(*value)[key], state)) {
success = false;
}
- out[key] = std::move(t);
+ out.emplace(key, std::move(t));
state->pop_stack();
}
return success;