From ab2256faeee71fcd9d505d744bfa3cfa257b3bc4 Mon Sep 17 00:00:00 2001 From: ringabout <43030857+ringabout@users.noreply.github.com> Date: Fri, 20 Mar 2026 11:15:27 +0800 Subject: [PATCH] fixes tuple unpacking for `nim ic` --- compiler/semstmts.nim | 2 ++ 1 file changed, 2 insertions(+) diff --git a/compiler/semstmts.nim b/compiler/semstmts.nim index 7e07143837..9812f90d06 100644 --- a/compiler/semstmts.nim +++ b/compiler/semstmts.nim @@ -781,6 +781,8 @@ proc makeVarTupleSection(c: PContext, n, a, def: PNode, typ: PType, symkind: TSy let temp = newSym(symkind, getIdent(c.cache, "tmpTuple"), c.idgen, getCurrOwner(c), n.info) temp.typ = typ temp.flagsImpl.incl(sfGenSym) + if getCurrOwner(c).kind == skModule: + temp.flagsImpl.incl(sfGlobal) lastDef = newNodeI(defkind, a.info) newSons(lastDef, 3) lastDef[0] = newSymNode(temp)