#pointers #data #unique #non #basic #type #multiple

no-std aliasable

Basic aliasable (non unique pointer) types

4 releases

0.1.3 Jan 10, 2021
0.1.2 Dec 8, 2020
0.1.1 Dec 8, 2020
0.1.0 Dec 7, 2020

#313 in Data structures

Download history 179499/week @ 2024-03-14 168528/week @ 2024-03-21 196183/week @ 2024-03-28 178317/week @ 2024-04-04 186286/week @ 2024-04-11 191690/week @ 2024-04-18 182257/week @ 2024-04-25 177233/week @ 2024-05-02 179591/week @ 2024-05-09 186154/week @ 2024-05-16 180354/week @ 2024-05-23 241917/week @ 2024-05-30 276608/week @ 2024-06-06 245088/week @ 2024-06-13 275638/week @ 2024-06-20 261669/week @ 2024-06-27

1,114,425 downloads per month
Used in 673 crates (4 directly)

MIT license

25KB
526 lines

Build Status Coverage Status Crate Docs

rust-aliasable

Rust library providing basic aliasable (non core::ptr::Unique) types
Documentation hosted on docs.rs.

aliasable = "0.1"

Why?

Used for escaping noalias when multiple raw pointers may point to the same data.

Goals

aliasable is not designed to provide a full interface for container types, simply to provide aliasable (non core::ptr::Unique) alternatives for dereferencing their owned data. When converting from a unique to an aliasable alternative, no data referenced is mutated (one-to-one internal representation aside from the non core::ptr::Unique pointer).

Usage

use aliasable::vec::AliasableVec;

// Re-exported via `aliasable::vec::UniqueVec`
let unique = Vec::from(&[1, 2, 3][..]);
let aliasable = AliasableVec::from(unique);

Dependencies