pub type ScopedString = Cow<'static, str>;Expand description
An allocation-optimized string.
We specify ScopedString to attempt to get the best of both worlds: flexibility to provide a
static or dynamic (owned) string, while retaining the performance benefits of being able to
take ownership of owned strings and borrows of completely static strings.
Aliased Type§
pub enum ScopedString {
Borrowed(&'static str),
Owned(String),
}