Registry / utility / compact-str

compact-str

JSON →
library0.9.1rscratesunverified

A memory efficient string type that transparently stores strings on the stack, when possible.

# Cargo.toml [dependencies] compact_str = "0.9.1"
INSTALL
IMPORT
SIG · COMPACT-STR
C
compact-str
utilityrustv0.9.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

CompactString
use compact_str::CompactString;

Creates a CompactString from a string literal and prints it.

use compact_str::CompactString; fn main() { let s = CompactString::new("hello"); println!("{}", s); }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.9.1latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
6
Resources
compact-str — cargo add compact-str · libregistry