mirror of https://github.com/YosysHQ/yosys.git
pool: add emplace() function
This commit is contained in:
parent
746c29b171
commit
a7c66fdc61
|
@ -871,6 +871,12 @@ public:
|
|||
return std::pair<iterator, bool>(iterator(this, i), true);
|
||||
}
|
||||
|
||||
template<typename... Args>
|
||||
std::pair<iterator, bool> emplace(Args&&... args)
|
||||
{
|
||||
return insert(K(std::forward<Args>(args)...));
|
||||
}
|
||||
|
||||
int erase(const K &key)
|
||||
{
|
||||
int hash = do_hash(key);
|
||||
|
|
Loading…
Reference in New Issue