From 10bd758d72bdea45db7e5a35d82e4f890b3c231c Mon Sep 17 00:00:00 2001 From: Clyybber Date: Thu, 12 Mar 2020 10:34:06 +0100 Subject: [PATCH] Fix #13633 --- compiler/extccomp.nim | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/compiler/extccomp.nim b/compiler/extccomp.nim index 34552e6f3bbf1..6f52e777a7e99 100644 --- a/compiler/extccomp.nim +++ b/compiler/extccomp.nim @@ -998,7 +998,8 @@ proc writeJsonBuildInstructions*(conf: ConfigRef) = f.write escapeJson(x) proc cfiles(conf: ConfigRef; f: File; buf: var string; clist: CfileList, isExternal: bool) = - for i, it in clist: + var i = 0 + for it in clist: if CfileFlag.Cached in it.flags: continue let compileCmd = getCompileCFileCmd(conf, it) if i > 0: lit ",\L" @@ -1007,6 +1008,7 @@ proc writeJsonBuildInstructions*(conf: ConfigRef) = lit ", " str compileCmd lit "]" + inc i proc linkfiles(conf: ConfigRef; f: File; buf, objfiles: var string; clist: CfileList; llist: seq[string]) =