You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/usr/lib64/gcc/x86_64-unknown-linux-gnu/4.8.1/../../../../include/c++/4.8.1/bits/stl_pair.h:134:35: error:
call to deleted constructor of 'std::unique_ptr<Creature, std::default_delete<Creature> >'
: first(std::forward<_U1>(__x)), second(__y) { }
The way you guys implement loading from map is by inserting
std::unique_ptr<Creature, std::default_delete<Creature> > >::pair<unsigned int &, void>' requested here
hint = map.insert(hint, {key, value} );
which violates std::unique_ptr.
function has been explicitly marked deleted here
unique_ptr(const unique_ptr&) = delete;
Probably this also breaks with other containers but I only tested it for std::multimap. I suggest looking into a solution that uses emplace instead of insert.
The text was updated successfully, but these errors were encountered:
All containers that used insert during loads (map, unordered_map, set, unordered_set)
now use emplace or emplace_hint and move their loaded values into position.
I get this:
The way you guys implement loading from map is by inserting
which violates std::unique_ptr.
Probably this also breaks with other containers but I only tested it for std::multimap. I suggest looking into a solution that uses emplace instead of insert.
The text was updated successfully, but these errors were encountered: