Fix example to reflect new usage of lazy_emplace_l - issue #143

This commit is contained in:
greg7mdp
2022-06-20 19:54:26 -04:00
parent eb60b8ac59
commit 9e87d79404
3 changed files with 7 additions and 4 deletions
+3 -3
View File
@@ -3276,10 +3276,10 @@ public:
return false;
}
// if map does not contains key, it is inserted and the mapped value is value-constructed
// with the provided arguments (if any), as with try_emplace.
// if map already contains key, then the lambda is called with the mapped value (under
// if map already contains key, the first lambda is called with the mapped value (under
// write lock protection) and can update the mapped value.
// if map does not contains key, the second lambda is called and it should invoke the
// passed constructor to construct the value
// returns true if key was not already present, false otherwise.
// ---------------------------------------------------------------------------------------
template <class K = key_type, class FExists, class FEmplace>