summary refs log tree commit diff stats
path: root/lib
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2019-07-01 10:35:52 +0200
committerAraq <rumpf_a@web.de>2019-07-01 10:35:52 +0200
commitdd39b11b139f5d7b94249e011698f453857ea92b (patch)
treeb1ccc190f24e01d10b9efe9781acd3a86d8b4b1e /lib
parentd37c4e44d3243acd91ffd91515e8a1807c979bad (diff)
downloadNim-dd39b11b139f5d7b94249e011698f453857ea92b.tar.gz
[bugfix] make -d:nimSetUtf8CodePage switch work again
Diffstat (limited to 'lib')
-rw-r--r--lib/system.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/system.nim b/lib/system.nim
index 61978e23c..256410522 100644
--- a/lib/system.nim
+++ b/lib/system.nim
@@ -4468,7 +4468,7 @@ proc substr*(s: string, first = 0): string =
 when defined(nimconfig):
   include "system/nimscript"
 
-when defined(windows) and appType == "console" and defined(nimSetUtf8CodePage):
+when defined(windows) and appType == "console" and defined(nimSetUtf8CodePage) and not defined(nimscript):
   proc setConsoleOutputCP(codepage: cint): cint {.stdcall, dynlib: "kernel32",
     importc: "SetConsoleOutputCP".}
   discard setConsoleOutputCP(65001) # 65001 - utf-8 codepage