mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 03:33:20 +01:00
DenseMap: Move the key into place when we use the move version of operator[].
llvm-svn: 183074
This commit is contained in:
parent
f7427d954c
commit
d88c18ff6c
@ -222,11 +222,11 @@ public:
|
||||
if (LookupBucketFor(Key, TheBucket))
|
||||
return *TheBucket;
|
||||
|
||||
return *InsertIntoBucket(Key, ValueT(), TheBucket);
|
||||
return *InsertIntoBucket(std::move(Key), ValueT(), TheBucket);
|
||||
}
|
||||
|
||||
ValueT &operator[](KeyT &&Key) {
|
||||
return FindAndConstruct(Key).second;
|
||||
return FindAndConstruct(std::move(Key)).second;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user