mirror of
https://github.com/VectorCamp/vectorscan.git
synced 2025-10-10 08:12:21 +03:00
replace push_back by emplace_back where possible
This commit is contained in:
committed by
Konstantinos Margaritis
parent
df769a9a9a
commit
7c6e47c95b
@@ -163,7 +163,7 @@ public:
|
||||
std::pair<iterator, bool> insert(const Key &key, const Element &element) {
|
||||
const auto idx = data.size();
|
||||
if (map.emplace(key, idx).second) {
|
||||
data.push_back(element);
|
||||
data.emplace_back(element);
|
||||
return {begin() + idx, true};
|
||||
}
|
||||
return {end(), false};
|
||||
|
Reference in New Issue
Block a user