implemented 'tags' pragma
This commit is contained in:
parent
a31a5f9c81
commit
48a62af3b1
9 changed files with 193 additions and 88 deletions
19
tests/reject/teffects3.nim
Normal file
19
tests/reject/teffects3.nim
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
discard """
|
||||
line: 18
|
||||
errormsg: "type mismatch"
|
||||
"""
|
||||
|
||||
type
|
||||
TObj = object {.pure, inheritable.}
|
||||
TObjB = object of TObj
|
||||
a, b, c: string
|
||||
fn: proc (): int {.tags: [].}
|
||||
|
||||
EIO2 = ref object of EIO
|
||||
|
||||
proc raiser(): int {.tags: [TObj].} =
|
||||
writeln stdout, "arg"
|
||||
|
||||
var o: TObjB
|
||||
o.fn = raiser
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue