summary refs log tree commit diff stats
path: root/compiler
diff options
context:
space:
mode:
authorringabout <43030857+ringabout@users.noreply.github.com>2024-03-28 18:04:12 +0800
committerGitHub <noreply@github.com>2024-03-28 11:04:12 +0100
commita24990bd8cca735fa1805279a7cd3f42e22240cd (patch)
treeb75c8caf3438799e63198acdb7faa359be9cb937 /compiler
parentafc30a3b936f35bdbfdc59b4e3d44f25a1273525 (diff)
downloadNim-a24990bd8cca735fa1805279a7cd3f42e22240cd.tar.gz
fixes #23429; rework `--verbosity` with warnings/hints (#23441)
fixes #23429
Diffstat (limited to 'compiler')
-rw-r--r--compiler/cmdlinehelper.nim5
1 files changed, 5 insertions, 0 deletions
diff --git a/compiler/cmdlinehelper.nim b/compiler/cmdlinehelper.nim
index 031ad755e..e51248639 100644
--- a/compiler/cmdlinehelper.nim
+++ b/compiler/cmdlinehelper.nim
@@ -57,6 +57,11 @@ proc loadConfigsAndProcessCmdLine*(self: NimProg, cache: IdentCache; conf: Confi
   if conf.cmd == cmdNimscript:
     incl(conf.globalOptions, optWasNimscript)
   loadConfigs(DefaultConfig, cache, conf, graph.idgen) # load all config files
+  # restores `conf.notes` after loading config files
+  # because it has overwrites the notes when compiling the system module which
+  # is a foreign module compared to the project
+  if conf.cmd in cmdBackends:
+    conf.notes = conf.mainPackageNotes
 
   if not self.suggestMode:
     let scriptFile = conf.projectFull.changeFileExt("nims")