Files
Nim/tests/cpp/torc.nim
ringabout 47b59e4d33 fix #17351; switch to c++17 and remove hacks (#20407)
* fix #17351; switch to c++17

* remove workaround
2022-09-23 11:16:43 +02:00

26 lines
312 B
Nim

discard """
targets: "cpp"
matrix: "--gc:orc"
"""
import std/options
# bug #18410
type
O = object of RootObj
val: pointer
proc p(): Option[O] = none(O)
doAssert $p() == "none(O)"
# bug #17351
type
Foo = object of RootObj
Foo2 = object of Foo
Bar = object
x: Foo2
var b = Bar()
discard b