summary refs log tree commit diff stats
path: root/compiler
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2018-04-13 23:48:56 +0200
committerAndreas Rumpf <rumpf_a@web.de>2018-04-13 23:48:56 +0200
commit9e884c31dd7a937f5d69b5303d5fc0a9e6b4c8f2 (patch)
tree3ec40c853ce7f1b484bc134d4ebb7f1db941740a /compiler
parentd7cc9016f3a457b0980259973f4b0089d25cd6bc (diff)
downloadNim-9e884c31dd7a937f5d69b5303d5fc0a9e6b4c8f2.tar.gz
the new feature's name is hotCodeReloading
Diffstat (limited to 'compiler')
-rw-r--r--compiler/commands.nim8
-rw-r--r--compiler/jsgen.nim6
-rw-r--r--compiler/options.nim2
3 files changed, 8 insertions, 8 deletions
diff --git a/compiler/commands.nim b/compiler/commands.nim
index 5b8f569ac..20727966b 100644
--- a/compiler/commands.nim
+++ b/compiler/commands.nim
@@ -473,10 +473,10 @@ proc processSwitch(switch, arg: string, pass: TCmdLinePass, info: TLineInfo;
     processOnOffSwitch({optMemTracker}, arg, pass, info)
     if optMemTracker in gOptions: defineSymbol("memtracker")
     else: undefSymbol("memtracker")
-  of "hotreloading":
-    processOnOffSwitch({optHotReloading}, arg, pass, info)
-    if optHotReloading in gOptions: defineSymbol("hotreloading")
-    else: undefSymbol("hotreloading")
+  of "hotcodereloading":
+    processOnOffSwitch({optHotCodeReloading}, arg, pass, info)
+    if optHotCodeReloading in gOptions: defineSymbol("hotcodereloading")
+    else: undefSymbol("hotcodereloading")
   of "oldnewlines":
     case arg.normalize
     of "on":
diff --git a/compiler/jsgen.nim b/compiler/jsgen.nim
index 6841482cd..da5267b93 100644
--- a/compiler/jsgen.nim
+++ b/compiler/jsgen.nim
@@ -255,7 +255,7 @@ proc mangleName(m: BModule, s: PSym): Rope =
         inc i
       result = rope(x)
     if s.name.s != "this" and s.kind != skField:
-      if optHotReloading in gOptions:
+      if optHotCodeReloading in gOptions:
         # When hot reloading is enabled, we must ensure that the names
         # of functions and types will be preserved across rebuilds:
         add(result, idOrSig(s, m.module.name.s, m.sigConflicts))
@@ -1584,7 +1584,7 @@ proc genVarInit(p: PProc, v: PSym, n: PNode) =
     s: Rope
     varCode: string
     varName = mangleName(p.module, v)
-    useReloadingGuard = sfGlobal in v.flags and optHotReloading in gOptions
+    useReloadingGuard = sfGlobal in v.flags and optHotCodeReloading in gOptions
 
   if v.constraint.isNil:
     if useReloadingGuard:
@@ -2208,7 +2208,7 @@ proc genProc(oldProc: PProc, prc: PSym): Rope =
   else:
     result = ~tnl
 
-    if optHotReloading in gOptions:
+    if optHotCodeReloading in gOptions:
       # Here, we introduce thunks that create the equivalent of a jump table
       # for all global functions, because references to them may be stored
       # in JavaScript variables. The added indirection ensures that such
diff --git a/compiler/options.nim b/compiler/options.nim
index d1428312b..40e97e94f 100644
--- a/compiler/options.nim
+++ b/compiler/options.nim
@@ -37,7 +37,7 @@ type                          # please make sure we have under 32 options
                               # evaluation
     optPatterns,              # en/disable pattern matching
     optMemTracker,
-    optHotReloading
+    optHotCodeReloading
 
   TOptions* = set[TOption]
   TGlobalOption* = enum       # **keep binary compatible**