| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/objects.h" | 5 #include "src/objects.h" |
| 6 | 6 |
| 7 #include <cmath> | 7 #include <cmath> |
| 8 #include <iomanip> | 8 #include <iomanip> |
| 9 #include <sstream> | 9 #include <sstream> |
| 10 | 10 |
| (...skipping 17313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 17324 | 17324 |
| 17325 void JSMap::Clear(Handle<JSMap> map) { | 17325 void JSMap::Clear(Handle<JSMap> map) { |
| 17326 Handle<OrderedHashMap> table(OrderedHashMap::cast(map->table())); | 17326 Handle<OrderedHashMap> table(OrderedHashMap::cast(map->table())); |
| 17327 table = OrderedHashMap::Clear(table); | 17327 table = OrderedHashMap::Clear(table); |
| 17328 map->set_table(*table); | 17328 map->set_table(*table); |
| 17329 } | 17329 } |
| 17330 | 17330 |
| 17331 | 17331 |
| 17332 void JSWeakCollection::Initialize(Handle<JSWeakCollection> weak_collection, | 17332 void JSWeakCollection::Initialize(Handle<JSWeakCollection> weak_collection, |
| 17333 Isolate* isolate) { | 17333 Isolate* isolate) { |
| 17334 DCHECK_EQ(0, weak_collection->map()->GetInObjectProperties()); | |
| 17335 Handle<ObjectHashTable> table = ObjectHashTable::New(isolate, 0); | 17334 Handle<ObjectHashTable> table = ObjectHashTable::New(isolate, 0); |
| 17336 weak_collection->set_table(*table); | 17335 weak_collection->set_table(*table); |
| 17337 } | 17336 } |
| 17338 | 17337 |
| 17339 | 17338 |
| 17340 void JSWeakCollection::Set(Handle<JSWeakCollection> weak_collection, | 17339 void JSWeakCollection::Set(Handle<JSWeakCollection> weak_collection, |
| 17341 Handle<Object> key, Handle<Object> value, | 17340 Handle<Object> key, Handle<Object> value, |
| 17342 int32_t hash) { | 17341 int32_t hash) { |
| 17343 DCHECK(key->IsJSReceiver() || key->IsSymbol()); | 17342 DCHECK(key->IsJSReceiver() || key->IsSymbol()); |
| 17344 Handle<ObjectHashTable> table( | 17343 Handle<ObjectHashTable> table( |
| (...skipping 682 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 18027 if (cell->value() != *new_value) { | 18026 if (cell->value() != *new_value) { |
| 18028 cell->set_value(*new_value); | 18027 cell->set_value(*new_value); |
| 18029 Isolate* isolate = cell->GetIsolate(); | 18028 Isolate* isolate = cell->GetIsolate(); |
| 18030 cell->dependent_code()->DeoptimizeDependentCodeGroup( | 18029 cell->dependent_code()->DeoptimizeDependentCodeGroup( |
| 18031 isolate, DependentCode::kPropertyCellChangedGroup); | 18030 isolate, DependentCode::kPropertyCellChangedGroup); |
| 18032 } | 18031 } |
| 18033 } | 18032 } |
| 18034 | 18033 |
| 18035 } // namespace internal | 18034 } // namespace internal |
| 18036 } // namespace v8 | 18035 } // namespace v8 |
| OLD | NEW |