From 8285e24805d505ec7904a3cd1b78fa90ba0df789 Mon Sep 17 00:00:00 2001 From: Araq Date: Tue, 20 Nov 2018 23:29:49 +0100 Subject: [PATCH] IR: also serialize the new transformedBody field --- compiler/rodimpl.nim | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/compiler/rodimpl.nim b/compiler/rodimpl.nim index c61c4ba04c..f2e0fd1a2d 100644 --- a/compiler/rodimpl.nim +++ b/compiler/rodimpl.nim @@ -321,6 +321,9 @@ proc encodeSym(g: ModuleGraph, s: PSym, result: var string) = result.add('\16') encodeVInt(s.gcUnsafetyReason.id, result) pushSym(w, s.gcUnsafetyReason) + if s.transformedBody != nil: + result.add('\24') + encodeNode(g, s.info, s.transformedBody, result) of skModule, skPackage: encodeInstantiations(g, s.usedGenerics, result) # we don't serialize: @@ -725,6 +728,9 @@ proc loadSymFromBlob(g; b; info: TLineInfo): PSym = if b.s[b.pos] == '\16': inc(b.pos) result.gcUnsafetyReason = loadSym(g, decodeVInt(b.s, b.pos), result.info) + if b.s[b.pos] == '\24': + inc b.pos + result.transformedBody = decodeNode(g, b, result.info) of skModule, skPackage: decodeInstantiations(g, b, result.info, result.usedGenerics) of skLet, skVar, skField, skForVar: