Registry / utility / unsize

unsize

JSON →
library1.1.0rscratesunverified

A stable alternative to CoerceUnsize.

# Cargo.toml [dependencies] unsize = "1.1.0"
INSTALL
IMPORT
SIG · UNSIZE
U
unsize
utilityrustv1.1.0
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.

Unsize
use unsize::Unsize;

Coerces a Vec into a slice using Unsize.

use unsize::Unsize; fn main() { let v: Vec<u8> = vec![1, 2, 3]; let slice: &[u8] = Unsize::unsize(&v); println!("Slice: {:?}", slice); }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
1.1.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
8 hits · last 30 days
node
8
Resources
unsize — cargo add unsize · libregistry