summary refs log blame commit diff stats
path: root/tests/effects/teffects4.nim
blob: 0025c10c5e0a609ccbae7ffe358e52e7a30fd6d9 (plain) (tree)
1
2
3
4
5
6
7
8
9








                                     
                                             
 
 
 
                               
         
 
                    
                         





             
discard """
  line: 23
  errormsg: "type mismatch"
"""

type
  TObj = object {.pure, inheritable.}
  TObjB = object of TObj
    a, b, c: string
    fn: proc (): int {.tags: [ReadIOEffect].}



proc q() {.tags: [IoEffect].} =
  discard

proc raiser(): int =
  writeLine stdout, "arg"
  if true:
    q()

var o: TObjB
o.fn = raiser