Fixed mutex usage in SharedList and SharedTable. Closes #6988 (#6990)

This commit is contained in:
Yuriy Glukhov 2017-12-31 11:28:51 +03:00 • committed by Andreas Rumpf
commit d1e10f9aa3
6 changed files with 31 additions and 13 deletions

View file

@ -213,7 +213,8 @@ block clearCountTableTest:
assert t.len() == 0
block withKeyTest:
var t = initSharedTable[int, int]()
var t: SharedTable[int, int]
t.init()
t.withKey(1) do (k: int, v: var int, pairExists: var bool):
assert(v == 0)
pairExists = true