diff options
Diffstat (limited to 'compiler/modules.nim')
-rw-r--r-- | compiler/modules.nim | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/compiler/modules.nim b/compiler/modules.nim index d653e8b8f..9a7f68495 100644 --- a/compiler/modules.nim +++ b/compiler/modules.nim @@ -105,10 +105,14 @@ proc checkDepMem(fileIdx: int32): TNeedRecompile = resetModule(fileIdx) return Yes - # cycle detection: We claim that a cycle does no harm. - if gMemCacheData[fileIdx].needsRecompile == Probing: - return No - #return gMemCacheData[fileIdx].needsRecompile + when true: + if gMemCacheData[fileIdx].needsRecompile != Maybe: + return gMemCacheData[fileIdx].needsRecompile + else: + # cycle detection: We claim that a cycle does no harm. + if gMemCacheData[fileIdx].needsRecompile == Probing: + return No + #return gMemCacheData[fileIdx].needsRecompile if optForceFullMake in gGlobalOptions or hashChanged(fileIdx): markDirty() |