Module ptr
Expand description
§Raw Pointer Implementation
This provides bitvec-internal pointer types and a mirror of the core::ptr
module.
It contains the following types:
BitPtris a raw-pointer to exactly one bit.BitRefis a proxy reference to exactly one bit.BitSpanis the encoded form of the*BitSlicepointer and&BitSlicereference. It is not publicly exposed, but it serves as the foundation ofbitvec’s ability to describe memory regions.
It also provides ports of the free functions available in core::ptr, as well
as some utilities for bridging ordinary Rust pointers into bitvec.
You should generally not use the contents of this module; BitSlice provides
more convenience and has stronger abilities to optimize performance.
Structs§
- BitPtr
- Single-Bit Pointer
- BitPtr
Range - Bit-Pointer Range
- BitRef
- Proxy Bit-Reference
- Const
- A basic
constmarker. - Misalign
Error - The error produced when an address is insufficiently aligned to the width of its type.
- Mut
- A basic
mutmarker.
Enums§
- BitPtr
Error - Errors produced by invalid bit-pointer components.
- BitSpan
Error - An error produced when creating
BitSpanencoded references.
Traits§
- Mutability
- Generalized mutability permissions.
Functions§
- bitslice_
from_ raw_ parts - Bit-Slice Pointer Construction
- bitslice_
from_ raw_ parts_ mut - Bit-Slice Pointer Construction
- check_
alignment - Ensures that an address is well-aligned to its referent type width.
- copy⚠
- Bit-wise
memcpy - copy_
nonoverlapping ⚠ - Bit-wise
memcpy - drop_
in_ ⚠place Deprecated - Remote Destructor
- eq
- Bit-Pointer Equality
- hash
- Bit-Pointer Hashing
- null
- Bit-Pointer Sentinel Value
- null_
mut - Bit-Pointer Sentinel Value
- read⚠
- Single-Bit Read
- read_
unaligned ⚠Deprecated - Single-Bit Unaligned Read
- read_
volatile ⚠ - Single-Bit Volatile Read
- replace⚠
- Single-Bit Replacement
- slice_
from_ raw_ parts - Raw Bit-Slice Pointer Construction
- slice_
from_ raw_ parts_ mut - Raw Bit-Slice Pointer Construction
- swap⚠
- Bit Swap
- swap_
nonoverlapping ⚠ - Many-Bit Swap
- write⚠
- Single-Bit Write
- write_
bits ⚠ - Bit-wise
memset - write_
bytes ⚠Deprecated - Bit-wise
memset - write_
unaligned ⚠Deprecated - Single-Bit Unaligned Write
- write_
volatile ⚠ - Single-Bit Volatile Write