fixes #1528
This commit is contained in:
parent
31bbc24462
commit
34ab1d3e34
3 changed files with 14 additions and 25 deletions
12
tests/discard/tvoidcontext.nim
Normal file
12
tests/discard/tvoidcontext.nim
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
discard """
|
||||
errormsg: "value of type 'string' has to be discarded"
|
||||
line: 12
|
||||
"""
|
||||
|
||||
proc valid*(): string =
|
||||
let x = 317
|
||||
"valid"
|
||||
|
||||
proc invalid*(): string =
|
||||
result = "foo"
|
||||
"invalid"
|
||||
Loading…
Add table
Add a link
Reference in a new issue