mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
default struct vals
This commit is contained in:
@@ -621,7 +621,7 @@ pub fn get_raw_line() string {
|
||||
max_line_chars := 256
|
||||
buf := &byte(malloc(max_line_chars*2))
|
||||
if is_atty(0) > 0 {
|
||||
h_input := C.GetStdHandle(C.STD_INPUT_HANDLE)
|
||||
h_input := C.GetStdHandle(STD_INPUT_HANDLE)
|
||||
mut nr_chars := u32(0)
|
||||
C.ReadConsole(h_input, buf, max_line_chars * 2, voidptr(&nr_chars), 0)
|
||||
return string_from_wide2(&u16(buf), int(nr_chars))
|
||||
|
||||
Reference in New Issue
Block a user