summary refs log tree commit diff stats
path: root/compiler/docgen2.nim
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2018-05-13 17:52:21 +0200
committerAndreas Rumpf <rumpf_a@web.de>2018-05-13 17:52:21 +0200
commit328e7a100560e5bd179512ba142ef944bf0a0698 (patch)
tree2403385aa6fc3461a810ca34222af8e3794b79cf /compiler/docgen2.nim
parent297038f70424e2d777cf7c308a9ab48cb6f66d01 (diff)
downloadNim-328e7a100560e5bd179512ba142ef944bf0a0698.tar.gz
options.nim: no global variables anymore
Diffstat (limited to 'compiler/docgen2.nim')
-rw-r--r--compiler/docgen2.nim4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/docgen2.nim b/compiler/docgen2.nim
index c975e6cc7..d9a73e1cd 100644
--- a/compiler/docgen2.nim
+++ b/compiler/docgen2.nim
@@ -25,8 +25,8 @@ template closeImpl(body: untyped) {.dirty.} =
   var g = PGen(p)
   let useWarning = sfMainModule notin g.module.flags
   #echo g.module.name.s, " ", g.module.owner.id, " ", gMainPackageId
-  if (g.module.owner.id == gMainPackageId and gWholeProject) or
-    sfMainModule in g.module.flags:
+  if (g.module.owner.id == gMainPackageId and optWholeProject in g.doc.conf.globalOptions) or
+      sfMainModule in g.module.flags:
     body
     try:
       generateIndex(g.doc)