Files
wren/test/core/map/churn.wren
T

12 lines
270 B
Plaintext
Raw Normal View History

2015-08-06 06:55:30 -07:00
// This is a regression test for a bug where inserting in a map would not
// correctly reuse tombstone entries, eventually deadlocking on insert.
var map = {}
for (i in 0...100) {
map[i] = i
if (i >= 10) map.remove(i - 10)
}
2015-09-15 07:46:09 -07:00
System.print(map.count) // expect: 10