fix #14312
This commit is contained in:
parent
55446c05a4
commit
2d7ccf0928
2 changed files with 22 additions and 8 deletions
|
|
@ -194,8 +194,6 @@ proc test_myobject =
|
|||
test_myobject()
|
||||
|
||||
|
||||
|
||||
|
||||
#------------------------------------------------
|
||||
# bug #14244
|
||||
|
||||
|
|
@ -212,3 +210,16 @@ proc init(): RocksDBResult[string] =
|
|||
result.value = "ok"
|
||||
|
||||
echo init()
|
||||
|
||||
|
||||
#------------------------------------------------
|
||||
# bug #14312
|
||||
|
||||
type MyObj = object
|
||||
case kind: bool
|
||||
of false: x0: int # would work with a type like seq[int]; value would be reset
|
||||
of true: x1: string
|
||||
|
||||
var a = MyObj(kind: false, x0: 1234)
|
||||
a.kind = true
|
||||
doAssert(a.x1 == "")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue