From 569d4f5c86a293a5ffdc45a8cf045aac1138bbab Mon Sep 17 00:00:00 2001 From: Speiger Date: Tue, 31 May 2022 19:05:54 +0200 Subject: [PATCH] Small Fix -Fixed: HashSet/Map.reduce was using size to iterate instead of array.length --- .../maps/impl/customHash/OpenCustomHashMap.template | 6 +++--- .../templates/maps/impl/hash/OpenHashMap.template | 6 +++--- .../collections/templates/sets/OpenCustomHashSet.template | 2 +- .../assets/collections/templates/sets/OpenHashSet.template | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/builder/resources/speiger/assets/collections/templates/maps/impl/customHash/OpenCustomHashMap.template b/src/builder/resources/speiger/assets/collections/templates/maps/impl/customHash/OpenCustomHashMap.template index 418e885..5241aee 100644 --- a/src/builder/resources/speiger/assets/collections/templates/maps/impl/customHash/OpenCustomHashMap.template +++ b/src/builder/resources/speiger/assets/collections/templates/maps/impl/customHash/OpenCustomHashMap.template @@ -942,7 +942,7 @@ public class CUSTOM_HASH_MAP KEY_VALUE_GENERIC_TYPE extends ABSTRACT_MAP KEY_VAL state = new BasicEntryKV_BRACES(keys[nullIndex], values[nullIndex]); empty = false; } - for(int i = 0;i=0;i--) { if(strategy.equals(keys[i], EMPTY_KEY_VALUE)) continue; if(empty) { empty = false; @@ -1173,7 +1173,7 @@ public class CUSTOM_HASH_MAP KEY_VALUE_GENERIC_TYPE extends ABSTRACT_MAP KEY_VAL state = keys[nullIndex]; empty = false; } - for(int i = 0;i=0;i--) { if(strategy.equals(keys[i], EMPTY_KEY_VALUE)) continue; if(empty) { empty = false; @@ -1329,7 +1329,7 @@ public class CUSTOM_HASH_MAP KEY_VALUE_GENERIC_TYPE extends ABSTRACT_MAP KEY_VAL state = values[nullIndex]; empty = false; } - for(int i = 0;i=0;i--) { if(strategy.equals(keys[i], EMPTY_KEY_VALUE)) continue; if(empty) { empty = false; diff --git a/src/builder/resources/speiger/assets/collections/templates/maps/impl/hash/OpenHashMap.template b/src/builder/resources/speiger/assets/collections/templates/maps/impl/hash/OpenHashMap.template index b207019..d32d0dc 100644 --- a/src/builder/resources/speiger/assets/collections/templates/maps/impl/hash/OpenHashMap.template +++ b/src/builder/resources/speiger/assets/collections/templates/maps/impl/hash/OpenHashMap.template @@ -902,7 +902,7 @@ public class HASH_MAP KEY_VALUE_GENERIC_TYPE extends ABSTRACT_MAP KEY_VALUE_GENE state = new BasicEntryKV_BRACES(keys[nullIndex], values[nullIndex]); empty = false; } - for(int i = 0;i=0;i--) { if(KEY_EQUALS_NULL(keys[i])) continue; if(empty) { empty = false; @@ -1129,7 +1129,7 @@ public class HASH_MAP KEY_VALUE_GENERIC_TYPE extends ABSTRACT_MAP KEY_VALUE_GENE state = keys[nullIndex]; empty = false; } - for(int i = 0;i=0;i--) { if(KEY_EQUALS_NULL(keys[i])) continue; if(empty) { empty = false; @@ -1285,7 +1285,7 @@ public class HASH_MAP KEY_VALUE_GENERIC_TYPE extends ABSTRACT_MAP KEY_VALUE_GENE state = values[nullIndex]; empty = false; } - for(int i = 0;i=0;i--) { if(KEY_EQUALS_NULL(keys[i])) continue; if(empty) { empty = false; diff --git a/src/builder/resources/speiger/assets/collections/templates/sets/OpenCustomHashSet.template b/src/builder/resources/speiger/assets/collections/templates/sets/OpenCustomHashSet.template index 9c3452e..00af4a1 100644 --- a/src/builder/resources/speiger/assets/collections/templates/sets/OpenCustomHashSet.template +++ b/src/builder/resources/speiger/assets/collections/templates/sets/OpenCustomHashSet.template @@ -589,7 +589,7 @@ public class CUSTOM_HASH_SET KEY_GENERIC_TYPE extends ABSTRACT_SET KEY_GENERIC_T state = keys[nullIndex]; empty = false; } - for(int i = 0;i=0;i--) { if(strategy.equals(keys[i], EMPTY_KEY_VALUE)) continue; if(empty) { empty = false; diff --git a/src/builder/resources/speiger/assets/collections/templates/sets/OpenHashSet.template b/src/builder/resources/speiger/assets/collections/templates/sets/OpenHashSet.template index 9762c3a..4511e03 100644 --- a/src/builder/resources/speiger/assets/collections/templates/sets/OpenHashSet.template +++ b/src/builder/resources/speiger/assets/collections/templates/sets/OpenHashSet.template @@ -452,7 +452,7 @@ public class HASH_SET KEY_GENERIC_TYPE extends ABSTRACT_SET KEY_GENERIC_TYPE imp state = keys[nullIndex]; empty = false; } - for(int i = 0;i=0;i--) { if(KEY_EQUALS_NULL(keys[i])) continue; if(empty) { empty = false;