This commit is contained in:
Andreas Rumpf 2021-10-05 12:29:59 +02:00 • committed by GitHub
commit f1f1e85ec6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -121,9 +121,9 @@ macro `=>`*(p, b: untyped): untyped =
else: else:
error("Incorrect procedure parameter.", c) error("Incorrect procedure parameter.", c)
params.add(identDefs) params.add(identDefs)
of nnkIdent: of nnkIdent, nnkOpenSymChoice, nnkClosedSymChoice, nnkSym:
var identDefs = newNimNode(nnkIdentDefs) var identDefs = newNimNode(nnkIdentDefs)
identDefs.add(p) identDefs.add(ident $p)
identDefs.add(ident"auto") identDefs.add(ident"auto")
identDefs.add(newEmptyNode()) identDefs.add(newEmptyNode())
params.add(identDefs) params.add(identDefs)