summary refs log tree commit diff stats
path: root/compiler/idgen.nim
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2016-06-22 02:50:42 +0200
committerAndreas Rumpf <rumpf_a@web.de>2016-06-22 02:50:50 +0200
commit4b0ba5e3f1b78b3c45a3f1576ed3d60f9a8b6d80 (patch)
tree2019e7f764acaaf4b5856febcffc6ae0eacf0a05 /compiler/idgen.nim
parent6b334770b5e310d8a237b88aed5d10380671f7d2 (diff)
downloadNim-4b0ba5e3f1b78b3c45a3f1576ed3d60f9a8b6d80.tar.gz
C code generation now deterministic; fixes #4364
Diffstat (limited to 'compiler/idgen.nim')
-rw-r--r--compiler/idgen.nim8
1 files changed, 1 insertions, 7 deletions
diff --git a/compiler/idgen.nim b/compiler/idgen.nim
index 906c16546..333772705 100644
--- a/compiler/idgen.nim
+++ b/compiler/idgen.nim
@@ -11,7 +11,7 @@
 
 import idents, strutils, os, options
 
-var gFrontEndId, gBackendId*: int
+var gFrontEndId*: int
 
 const
   debugIds* = false
@@ -30,10 +30,6 @@ proc getID*(): int {.inline.} =
   result = gFrontEndId
   inc(gFrontEndId)
 
-proc backendId*(): int {.inline.} =
-  result = gBackendId
-  inc(gBackendId)
-
 proc setId*(id: int) {.inline.} =
   gFrontEndId = max(gFrontEndId, id + 1)
 
@@ -49,7 +45,6 @@ proc toGid(f: string): string =
 proc saveMaxIds*(project: string) =
   var f = open(project.toGid, fmWrite)
   f.writeLine($gFrontEndId)
-  f.writeLine($gBackendId)
   f.close()
 
 proc loadMaxIds*(project: string) =
@@ -61,5 +56,4 @@ proc loadMaxIds*(project: string) =
       if f.readLine(line):
         var backEndId = parseInt(line)
         gFrontEndId = max(gFrontEndId, frontEndId)
-        gBackendId = max(gBackendId, backEndId)
     f.close()