bugfixes; step one for 'var T' as return type support
This commit is contained in:
parent
e7135c449d
commit
2f066395ba
27 changed files with 234 additions and 68 deletions
16
tests/reject/tvarres2.nim
Normal file
16
tests/reject/tvarres2.nim
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
discard """
|
||||
file: "tvarres1.nim"
|
||||
line: 11
|
||||
errormsg: "expression has no address"
|
||||
"""
|
||||
|
||||
var
|
||||
g = 5
|
||||
|
||||
proc p(): var int =
|
||||
result = 89
|
||||
|
||||
p() = 45
|
||||
|
||||
echo g
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue