mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
os: fix get_line in windows
This commit is contained in:
parent
cbd4478b5e
commit
279f7d57cb
@ -333,6 +333,7 @@ fn (v mut V) generate_main() {
|
|||||||
cgen.genln('void init_consts() {
|
cgen.genln('void init_consts() {
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
#ifndef _BOOTSTRAP_NO_UNICODE_STREAM
|
#ifndef _BOOTSTRAP_NO_UNICODE_STREAM
|
||||||
|
_setmode(_fileno(stdin), _O_U16TEXT);
|
||||||
_setmode(_fileno(stdout), _O_U8TEXT);
|
_setmode(_fileno(stdout), _O_U8TEXT);
|
||||||
SetConsoleMode(GetStdHandle(STD_OUTPUT_HANDLE), ENABLE_PROCESSED_OUTPUT | 0x0004);
|
SetConsoleMode(GetStdHandle(STD_OUTPUT_HANDLE), ENABLE_PROCESSED_OUTPUT | 0x0004);
|
||||||
// ENABLE_VIRTUAL_TERMINAL_PROCESSING
|
// ENABLE_VIRTUAL_TERMINAL_PROCESSING
|
||||||
|
Loading…
Reference in New Issue
Block a user