Use array based storage in container objects (#3600)
Currently, collections use object based solutions for storing elements and iterating on them. If an element is deleted and re-inserted, the storage position is the same as before so the iteration order is wrong. This patch replaces the object based storage with an array based solution that helps to store and iterate elements as expected. JerryScript-DCO-1.0-Signed-off-by: Roland Takacs rtakacs@inf.u-szeged.hu
This commit is contained in:
@@ -115,7 +115,7 @@ m1.set(k1, "str");
|
||||
m1.set(k1, "4");
|
||||
m1.set(k1, null);
|
||||
m1.set(k1, 42);
|
||||
print (m1.has (k1));
|
||||
assert (m1.has (k1));
|
||||
k1 = {};
|
||||
gc();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user