File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ unicode-width = { version = "0.2", optional = true }
23
23
lazy_static = " 1.4.0"
24
24
25
25
[target .'cfg(windows)' .dependencies ]
26
- encode_unicode = " 0.3 "
26
+ encode_unicode = " 1 "
27
27
28
28
[target .'cfg(windows)' .dependencies .windows-sys ]
29
29
version = " 0.52.0"
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ use std::os::windows::ffi::OsStrExt;
10
10
use std:: os:: windows:: io:: AsRawHandle ;
11
11
use std:: { char, mem:: MaybeUninit } ;
12
12
13
- use encode_unicode:: error:: InvalidUtf16Tuple ;
13
+ use encode_unicode:: error:: Utf16TupleError ;
14
14
use encode_unicode:: CharExt ;
15
15
use windows_sys:: Win32 :: Foundation :: { HANDLE , INVALID_HANDLE_VALUE , MAX_PATH } ;
16
16
use windows_sys:: Win32 :: Storage :: FileSystem :: { FileNameInfo , GetFileInformationByHandleEx } ;
@@ -398,13 +398,13 @@ pub fn read_single_key(_ctrlc_key: bool) -> io::Result<Key> {
398
398
}
399
399
}
400
400
// This is part of a surrogate pair. Try to read the second half.
401
- Err ( InvalidUtf16Tuple :: MissingSecond ) => {
401
+ Err ( Utf16TupleError :: MissingSecond ) => {
402
402
// Confirm that there is a next character to read.
403
403
if get_key_event_count ( ) ? == 0 {
404
404
let message = format ! (
405
405
"Read invlid utf16 {}: {}" ,
406
406
unicode_char,
407
- InvalidUtf16Tuple :: MissingSecond
407
+ Utf16TupleError :: MissingSecond
408
408
) ;
409
409
return Err ( io:: Error :: new ( io:: ErrorKind :: InvalidData , message) ) ;
410
410
}
You can’t perform that action at this time.
0 commit comments