parent
0a14b3d198
commit
d146045ed5
2 changed files with 24 additions and 3 deletions
|
|
@ -91,6 +91,21 @@ block:
|
|||
result = size
|
||||
doAssert f(4) == 4
|
||||
|
||||
# #6689
|
||||
block:
|
||||
static:
|
||||
proc foo(): int = 0
|
||||
var f: proc(): int
|
||||
doAssert f.isNil
|
||||
f = foo
|
||||
doAssert(not f.isNil)
|
||||
|
||||
block:
|
||||
static:
|
||||
var x: ref ref int
|
||||
new(x)
|
||||
doAssert(not x.isNil)
|
||||
|
||||
# #7871
|
||||
static:
|
||||
type Obj = object
|
||||
|
|
@ -119,4 +134,4 @@ static:
|
|||
o.names = ""
|
||||
o.pushName()
|
||||
o.pushName()
|
||||
doAssert o.names == "FOOBARFOOBAR"
|
||||
doAssert o.names == "FOOBARFOOBAR"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue