summary refs log tree commit diff stats
path: root/compiler
diff options
context:
space:
mode:
authorEduardo Bart <edub4rt@gmail.com>2017-10-09 14:09:49 -0300
committerAndreas Rumpf <rumpf_a@web.de>2017-10-09 19:09:49 +0200
commit5c1a842b881525a77dda40af8cf9bdd6432e25de (patch)
tree9fd9ec119bda079d8a02b39b92357e789a8a5889 /compiler
parentd55e02ddf12662781cf89e2fd91473dbf7552e5a (diff)
downloadNim-5c1a842b881525a77dda40af8cf9bdd6432e25de.tar.gz
Add missing nilChecks compiling option (#6480)
Diffstat (limited to 'compiler')
-rw-r--r--compiler/commands.nim2
1 files changed, 2 insertions, 0 deletions
diff --git a/compiler/commands.nim b/compiler/commands.nim
index cd2241995..ce50b1a79 100644
--- a/compiler/commands.nim
+++ b/compiler/commands.nim
@@ -251,6 +251,7 @@ proc testCompileOption*(switch: string, info: TLineInfo): bool =
     result = gOptions * {optNaNCheck, optInfCheck} == {optNaNCheck, optInfCheck}
   of "infchecks": result = contains(gOptions, optInfCheck)
   of "nanchecks": result = contains(gOptions, optNaNCheck)
+  of "nilchecks": result = contains(gOptions, optNilCheck)
   of "objchecks": result = contains(gOptions, optObjCheck)
   of "fieldchecks": result = contains(gOptions, optFieldCheck)
   of "rangechecks": result = contains(gOptions, optRangeCheck)
@@ -473,6 +474,7 @@ proc processSwitch(switch, arg: string, pass: TCmdLinePass, info: TLineInfo;
     processOnOffSwitch({optNaNCheck, optInfCheck}, arg, pass, info)
   of "infchecks": processOnOffSwitch({optInfCheck}, arg, pass, info)
   of "nanchecks": processOnOffSwitch({optNaNCheck}, arg, pass, info)
+  of "nilchecks": processOnOffSwitch({optNilCheck}, arg, pass, info)
   of "objchecks": processOnOffSwitch({optObjCheck}, arg, pass, info)
   of "fieldchecks": processOnOffSwitch({optFieldCheck}, arg, pass, info)
   of "rangechecks": processOnOffSwitch({optRangeCheck}, arg, pass, info)