Crate quetta[][src]

Expand description

quetta (from the Quenya word for “word”) is a library providing simple immutable strings in Rust. Essentially, it is a wrapper around Arc<str>, but with support for slicing and compatibility features with &str.

The primary type provided by quetta is Text. Text can be either a full string or a slice from another Text, but this is of no concern to the user. Text is immutable and can be cloned very cheaply.

Example

use quetta::Text;

let t = Text::new("a.b.c");
let s1 = t.slice(0, 2);
assert_eq!("a.", s1.as_str());

Structs

The primary type of quetta, representing an immutable sequence of characters. Internally, this can be either a full string or a slice into another Text. Can be cloned cheaply.