Trait aoko::no_std::functions::ext::Utf8Ext[][src]

pub trait Utf8Ext<'a> {
    fn to_str(self) -> Result<&'a str, Utf8Error>;
}
Expand description

This trait is to implement some extension functions for &[u8] and Vec<u8> type.

Required methods

Implementations on Foreign Types

Converts a slice of bytes to a string slice.

Examples
use aoko::no_std::functions::ext::*;
 
assert_eq!("💖", [240, 159, 146, 150].to_str().unwrap());

Implementors