summary refs log tree commit diff stats
path: root/compiler/suggest.nim
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2018-05-29 08:22:09 +0200
committerAndreas Rumpf <rumpf_a@web.de>2018-05-29 08:22:09 +0200
commita5701d6b71853e683f4d655b6b5ea4a13bec993b (patch)
treebe1c3b3e862ce18636de0482d76d2f0a96a49b8d /compiler/suggest.nim
parent06122ff7116e699a50c968bb0192e6faf00fa6ef (diff)
downloadNim-a5701d6b71853e683f4d655b6b5ea4a13bec993b.tar.gz
ensure compiler API doesn't import the RST engine
Diffstat (limited to 'compiler/suggest.nim')
-rw-r--r--compiler/suggest.nim4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/suggest.nim b/compiler/suggest.nim
index 391906c3f..b66dbce68 100644
--- a/compiler/suggest.nim
+++ b/compiler/suggest.nim
@@ -115,7 +115,7 @@ proc symToSuggest(conf: ConfigRef; s: PSym, isLocal: bool, section: IdeCmd, info
       result.forth = typeToString(s.typ)
     else:
       result.forth = ""
-    when not defined(noDocgen):
+    when defined(nimsuggest) and not defined(noDocgen):
       result.doc = s.extractDocComment
   let infox = if section in {ideUse, ideHighlight, ideOutline}: info else: s.info
   result.filePath = toFullPath(conf, infox)
@@ -153,7 +153,7 @@ proc `$`*(suggest: Suggest): string =
     result.add(sep)
     result.add($suggest.column)
     result.add(sep)
-    when not defined(noDocgen):
+    when defined(nimsuggest) and not defined(noDocgen):
       result.add(suggest.doc.escape)
     if suggest.version == 0:
       result.add(sep)