workaround bug in sharedtables.withValue to unblock frozen CI on OSX (#18172)
This commit is contained in:
parent
5423915e5a
commit
a77360da5b
1 changed files with 4 additions and 0 deletions
|
|
@ -108,10 +108,14 @@ template withValue*[A, B](t: var SharedTable[A, B], key: A,
|
|||
table.withValue("a", value):
|
||||
value[] = "m"
|
||||
|
||||
var flag = false
|
||||
table.withValue("d", value):
|
||||
discard value
|
||||
doAssert false
|
||||
do: # if "d" notin table
|
||||
flag = true
|
||||
|
||||
if flag:
|
||||
table["d"] = "n"
|
||||
|
||||
assert table.mget("a") == "m"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue