| Index: corelib/src/implementation/hash_map_set.dart
|
| diff --git a/corelib/src/implementation/hash_map_set.dart b/corelib/src/implementation/hash_map_set.dart
|
| index caea8659e6c5e07736efddd622fcad19394e6b01..a05f9f5a4a6374b73189b5411dbef045f7f8e3a1 100644
|
| --- a/corelib/src/implementation/hash_map_set.dart
|
| +++ b/corelib/src/implementation/hash_map_set.dart
|
| @@ -228,8 +228,9 @@ class HashMapImplementation<K extends Hashable, V> implements HashMap<K, V> {
|
| void forEach(void f(K key, V value)) {
|
| int length = _keys.length;
|
| for (int i = 0; i < length; i++) {
|
| - if ((_keys[i] !== null) && (_keys[i] !== _DELETED_KEY)) {
|
| - f(_keys[i], _values[i]);
|
| + K key = _keys[i];
|
| + if ((key !== null) && (key !== _DELETED_KEY)) {
|
| + f(key, _values[i]);
|
| }
|
| }
|
| }
|
| @@ -260,7 +261,8 @@ class HashMapImplementation<K extends Hashable, V> implements HashMap<K, V> {
|
| bool containsValue(V value) {
|
| int length = _values.length;
|
| for (int i = 0; i < length; i++) {
|
| - if ((_keys[i] !== null) && (_keys[i] !== _DELETED_KEY)) {
|
| + K key = _keys[i];
|
| + if ((key !== null) && (key !== _DELETED_KEY)) {
|
| if (_values[i] == value) return true;
|
| }
|
| }
|
|
|