summary refs log tree commit diff stats
path: root/compiler
diff options
context:
space:
mode:
authorNikolay Nikolov <nickysn@gmail.com>2023-11-24 20:55:53 +0200
committerGitHub <noreply@github.com>2023-11-24 19:55:53 +0100
commit502a4486aeb8d0a5dcdf86540522d3dc16960536 (patch)
treeb53b42cf0b5aee7ef155aa3dd0d7a9d666817161 /compiler
parent816ddd8be7cbae2513469cfccc516169a0cad7b2 (diff)
downloadNim-502a4486aeb8d0a5dcdf86540522d3dc16960536.tar.gz
nimsuggest: Added optional command line option '--clientProcessId:XXX' (#22969)
When it is specified, the nimsuggest instance monitors whether this
process is still alive. In case it's found to be dead, nimsuggest shuts
itself down. Currently only implemented on POSIX and Windows platforms.
The switch is silently ignored on other platforms. Note that the Nim
language server should still try to shut down its child nimsuggest
processes. This switch just adds extra protection against crashing Nim
language server and gets rid of the remaining nimsuggest processes,
which consume memory and system resources.
Diffstat (limited to 'compiler')
-rw-r--r--compiler/options.nim1
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/options.nim b/compiler/options.nim
index e50acbf49..3731304c7 100644
--- a/compiler/options.nim
+++ b/compiler/options.nim
@@ -442,6 +442,7 @@ type
     expandPosition*: TLineInfo
 
     currentConfigDir*: string # used for passPP only; absolute dir
+    clientProcessId*: int
 
 
 proc parseNimVersion*(a: string): NimVer =