added test for result shadow warning
This commit is contained in:
parent
a1d813d12c
commit
f592240c54
1 changed files with 7 additions and 0 deletions
7
tests/exprs/tresultwarning.nim
Normal file
7
tests/exprs/tresultwarning.nim
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
discard """
|
||||||
|
msg: "Special variable 'result' is shadowed. [ResultShadowed]"
|
||||||
|
line: 7
|
||||||
|
"""
|
||||||
|
|
||||||
|
proc test(): string =
|
||||||
|
var result = "foo"
|
||||||
Loading…
Add table
Add a link
Reference in a new issue