Struct std::string::FromUtf16Error
1.0.0 · source · pub struct FromUtf16Error(_);
Expand description
从 UTF-16 字节切片转换 String
时可能的错误值。
该类型是 String
上 from_utf16
方法的错误类型。
Examples
基本用法:
// 𝄞mu<invalid>ic
let v = &[0xD834, 0xDD1E, 0x006d, 0x0075,
0xD800, 0x0069, 0x0063];
assert!(String::from_utf16(v).is_err());
RunTrait Implementations§
source§impl Debug for FromUtf16Error
impl Debug for FromUtf16Error
source§impl Display for FromUtf16Error
impl Display for FromUtf16Error
Auto Trait Implementations§
impl RefUnwindSafe for FromUtf16Error
impl Send for FromUtf16Error
impl Sync for FromUtf16Error
impl Unpin for FromUtf16Error
impl UnwindSafe for FromUtf16Error
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
从拥有的值中借用。 Read more