disallow recursive module dependencies
This commit is contained in:
parent
204838b358
commit
074f276c8a
14 changed files with 47 additions and 45 deletions
|
|
@ -231,6 +231,7 @@ proc compileProject*(graph: ModuleGraph; cache: IdentCache;
|
|||
wantMainModule()
|
||||
let systemFileIdx = fileInfoIdx(options.libpath / "system.nim")
|
||||
let projectFile = if projectFileIdx < 0: gProjectMainIdx else: projectFileIdx
|
||||
graph.importStack.add projectFile
|
||||
if projectFile == systemFileIdx:
|
||||
discard graph.compileModule(projectFile, cache, {sfMainModule, sfSystemModule})
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue