| Index: third_party/WebKit/Source/modules/indexeddb/IDBKey.h
|
| diff --git a/third_party/WebKit/Source/modules/indexeddb/IDBKey.h b/third_party/WebKit/Source/modules/indexeddb/IDBKey.h
|
| index cbbf32c3dac8ffbf69dcfd5961744206b8f61e62..04be992612058233aab08123232b089514f459c2 100644
|
| --- a/third_party/WebKit/Source/modules/indexeddb/IDBKey.h
|
| +++ b/third_party/WebKit/Source/modules/indexeddb/IDBKey.h
|
| @@ -32,6 +32,7 @@
|
| #include "wtf/Forward.h"
|
| #include "wtf/Vector.h"
|
| #include "wtf/text/WTFString.h"
|
| +#include <utility>
|
|
|
| namespace blink {
|
|
|
| @@ -55,28 +56,7 @@ class MODULES_EXPORT IDBKey : public GarbageCollectedFinalized<IDBKey> {
|
|
|
| static IDBKey* createDate(double date) { return new IDBKey(DateType, date); }
|
|
|
| - static IDBKey* createMultiEntryArray(const KeyArray& array) {
|
| - KeyArray result;
|
| -
|
| - for (size_t i = 0; i < array.size(); i++) {
|
| - if (!array[i]->isValid())
|
| - continue;
|
| -
|
| - bool skip = false;
|
| - for (size_t j = 0; j < result.size(); j++) {
|
| - if (array[i]->isEqual(result[j].get())) {
|
| - skip = true;
|
| - break;
|
| - }
|
| - }
|
| - if (!skip) {
|
| - result.push_back(array[i]);
|
| - }
|
| - }
|
| - IDBKey* idbKey = new IDBKey(result);
|
| - ASSERT(idbKey->isValid());
|
| - return idbKey;
|
| - }
|
| + static IDBKey* createMultiEntryArray(const KeyArray&);
|
|
|
| static IDBKey* createArray(const KeyArray& array) {
|
| return new IDBKey(array);
|
| @@ -136,6 +116,8 @@ class MODULES_EXPORT IDBKey : public GarbageCollectedFinalized<IDBKey> {
|
| : m_type(BinaryType), m_binary(value) {}
|
| explicit IDBKey(const KeyArray& keyArray)
|
| : m_type(ArrayType), m_array(keyArray) {}
|
| + explicit IDBKey(KeyArray&& keyArray)
|
| + : m_type(ArrayType), m_array(std::move(keyArray)) {}
|
|
|
| const Type m_type;
|
| const KeyArray m_array;
|
|
|