diff --git a/compiler/vmdef.nim b/compiler/vmdef.nim index a3ac120f99..8310062dbb 100644 --- a/compiler/vmdef.nim +++ b/compiler/vmdef.nim @@ -308,7 +308,7 @@ proc newCtx*(module: PSym; cache: IdentCache; g: ModuleGraph; idgen: IdGenerator callDepth: g.config.maxCallDepthVM, comesFromHeuristic: unknownLineInfo, callbacks: @[], callbackIndex: initTable[string, int](), errorFlag: "", cache: cache, config: g.config, graph: g, idgen: idgen, - contstantTab: initNodeTable(true)) + contstantTab: initNodeTable(true), templInstCounter: new int) proc refresh*(c: PCtx, module: PSym; idgen: IdGenerator) = c.module = module diff --git a/tests/vm/tquote.nim b/tests/vm/tquote.nim new file mode 100644 index 0000000000..3b4c520519 --- /dev/null +++ b/tests/vm/tquote.nim @@ -0,0 +1,13 @@ +discard """ + joinable: false +""" + +import std/macros + +static: + discard quote: + a and b + +var x {.compileTime.} : NimNode = + quote do: + echo "xxx" \ No newline at end of file