diff options
Diffstat (limited to 'compiler/ic/cbackend.nim')
-rw-r--r-- | compiler/ic/cbackend.nim | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/ic/cbackend.nim b/compiler/ic/cbackend.nim index 97462f095..c2e6b08fe 100644 --- a/compiler/ic/cbackend.nim +++ b/compiler/ic/cbackend.nim @@ -147,12 +147,12 @@ proc generateCode*(g: ModuleGraph) = var alive = computeAliveSyms(g.packed, g.config) when false: - for i in 0..high(g.packed): + for i in 0..<len(g.packed): echo i, " is of status ", g.packed[i].status, " ", toFullPath(g.config, FileIndex(i)) # First pass: Setup all the backend modules for all the modules that have # changed: - for i in 0..high(g.packed): + for i in 0..<len(g.packed): # case statement here to enforce exhaustive checks. case g.packed[i].status of undefined: @@ -174,7 +174,7 @@ proc generateCode*(g: ModuleGraph) = let mainModuleIdx = g.config.projectMainIdx2.int # We need to generate the main module last, because only then # all init procs have been registered: - for i in 0..high(g.packed): + for i in 0..<len(g.packed): if i != mainModuleIdx: genPackedModule(g, i, alive) if mainModuleIdx >= 0: |