summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
authorringabout <43030857+ringabout@users.noreply.github.com>2023-03-09 15:09:08 +0800
committerGitHub <noreply@github.com>2023-03-09 08:09:08 +0100
commit72e262666bdf2bb3c239183dd32b48bb05d113aa (patch)
tree263bea109063b9700efcdb523ea8db5e09a950f5 /tests
parent8e9fc5e63968177c75d93af08d32717bf6c97693 (diff)
downloadNim-72e262666bdf2bb3c239183dd32b48bb05d113aa.tar.gz
fixes quoted variables with typedesc types (#21493)
Diffstat (limited to 'tests')
-rw-r--r--tests/stdlib/tmacros.nim8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/stdlib/tmacros.nim b/tests/stdlib/tmacros.nim
index a03bcca2d..9e3ebee83 100644
--- a/tests/stdlib/tmacros.nim
+++ b/tests/stdlib/tmacros.nim
@@ -311,3 +311,11 @@ block: # bug #9607
 
   doAssert echoL() == "bar"
   doAssert echoM() == "bar"
+
+block:
+  macro hello[T](x: T): untyped =
+    result = quote do:
+      let m: `T` = `x`
+      discard m
+
+  hello(12)