Skip to content

carllerche/string

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

String

A UTF-8 encoded string with configurable byte storage.

Build Status License: MIT Crates.io Documentation

Usage

To use string, first add this to your Cargo.toml:

[dependencies]
string = "0.3.0"

Next, add this to your crate:

extern crate string;

use string::{String, TryFrom};

let s: String<[u8; 2]> = String::try_from([b'h', b'i']).unwrap();
assert_eq!(&s[..], "hi");

See documentation for more details.

About

Rust String type with configurable byte storage.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Languages