summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2017-09-20 14:18:55 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2017-10-17 11:18:33 +0000
commit42d8ea5645c3ca84d56537e7b86ef079418cb636 (patch)
tree2350e3d7a76ad158d1f71b44cd9ad5d2f13c0e98
parent260f8350e1fad3afd8d15e6f4f176884b5ebb482 (diff)
downloadqtwebengine-chromium-42d8ea5645c3ca84d56537e7b86ef079418cb636.tar.gz
FIXUP: Fix build with GCC 7.0
Reinstate warning fix lost in original cherry-pick Change-Id: Id3a4c25a4648c88681f3312d2b73312a5884a5c2 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
-rw-r--r--chromium/v8/src/objects-inl.h18
-rw-r--r--chromium/v8/src/objects/hash-table.h16
2 files changed, 20 insertions, 14 deletions
diff --git a/chromium/v8/src/objects-inl.h b/chromium/v8/src/objects-inl.h
index 406f49d9969..dcf695a6c68 100644
--- a/chromium/v8/src/objects-inl.h
+++ b/chromium/v8/src/objects-inl.h
@@ -7847,6 +7847,24 @@ bool GlobalDictionaryShape::IsDeleted(Dictionary* dict, int entry) {
}
+template <typename Derived, typename Shape, typename Key>
+inline uint32_t HashTable<Derived,Shape,Key>::Hash(Key key) {
+ if (Shape::UsesSeed) {
+ return Shape::SeededHash(key, GetHeap()->HashSeed());
+ } else {
+ return Shape::Hash(key);
+ }
+}
+
+template <typename Derived, typename Shape, typename Key>
+inline uint32_t HashTable<Derived,Shape,Key>::HashForObject(Key key, Object* object) {
+ if (Shape::UsesSeed) {
+ return Shape::SeededHashForObject(key, GetHeap()->HashSeed(), object);
+ } else {
+ return Shape::HashForObject(key, object);
+ }
+}
+
bool ObjectHashTableShape::IsMatch(Handle<Object> key, Object* other) {
return key->SameValue(other);
}
diff --git a/chromium/v8/src/objects/hash-table.h b/chromium/v8/src/objects/hash-table.h
index f3c68a82c5e..2a9a156cdb6 100644
--- a/chromium/v8/src/objects/hash-table.h
+++ b/chromium/v8/src/objects/hash-table.h
@@ -139,21 +139,9 @@ class HashTable : public HashTableBase {
typedef Shape ShapeT;
// Wrapper methods
- inline uint32_t Hash(Key key) {
- if (Shape::UsesSeed) {
- return Shape::SeededHash(key, GetHeap()->HashSeed());
- } else {
- return Shape::Hash(key);
- }
- }
+ inline uint32_t Hash(Key key);
- inline uint32_t HashForObject(Key key, Object* object) {
- if (Shape::UsesSeed) {
- return Shape::SeededHashForObject(key, GetHeap()->HashSeed(), object);
- } else {
- return Shape::HashForObject(key, object);
- }
- }
+ inline uint32_t HashForObject(Key key, Object* object);
// Returns a new HashTable object.
MUST_USE_RESULT static Handle<Derived> New(