pub struct Pair64<T = u64> { /* private fields */ }
Expand description

A pair of Pack64s, allowing a bit range to be unpacked from one offset in a u64 value, and packed into a different offset in a different value.

See the module-level documentation for details on using packing specs.

Implementations

Returns the “source” member of the packing pair.

Returns the “destination” member of the packing pair.

Pack bits from the source location in src into the destination location in dst.

Pack bits from the destination location in dst into the source location in src.

Asserts that this packing pair is valid.

Because assertions cannot be made in const fn, this performs validating assertions that would ideally be made when constructing a new instance of this type. When packing specs are declared as consts, this method can be called in a unit test to ensure that the spec is valid.

Trait Implementations

Formats the value using the given formatter.

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Formats the value using the given formatter.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Formats the value using the given formatter.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.