diff options
author | Jake Leahy <jake@leahy.dev> | 2022-11-28 06:09:25 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-27 20:09:25 +0100 |
commit | d26b1232ee7a69c2a71db81aa0185499321c54fe (patch) | |
tree | cc42030864d72f3078437791b2dc25651569a091 /tests | |
parent | 5a848a070759c4b5fa868741b430f96586a9ac18 (diff) | |
download | Nim-d26b1232ee7a69c2a71db81aa0185499321c54fe.tar.gz |
Add `nkFastAsgn` into `semExpr` (#20939)
* Add nkFastAsgn into case statement * Add test case
Diffstat (limited to 'tests')
-rw-r--r-- | tests/magics/t20938.nim | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/magics/t20938.nim b/tests/magics/t20938.nim new file mode 100644 index 000000000..7341cbb91 --- /dev/null +++ b/tests/magics/t20938.nim @@ -0,0 +1,12 @@ +discard """ + cmd: "nim c --mm:refc $file" + action: "compile" +""" + +template foo(x: typed) = + discard x + +foo: + var x = "hello" + x.shallowCopy("test") + true |