Skip to main content

MontyFieldBytes

Type Alias MontyFieldBytes 

Source
pub type MontyFieldBytes<MOD, const LIMBS: usize> = Array<u8, <MOD as MontyFieldParams<LIMBS>>::ByteSize>;
Expand description

Serialized representation of a field element.

Aliased Type§

#[repr(transparent)]
pub struct MontyFieldBytes<MOD, const LIMBS: usize>(pub <<MOD as MontyFieldParams<LIMBS>>::ByteSize as ArraySize>::ArrayType<u8>);

Tuple Fields§

§0: <<MOD as MontyFieldParams<LIMBS>>::ByteSize as ArraySize>::ArrayType<u8>

Trait Implementations§

Source§

impl<MOD, const LIMBS: usize> From<&MontyFieldElement<MOD, LIMBS>> for MontyFieldBytes<MOD, LIMBS>
where MOD: MontyFieldParams<LIMBS>, Uint<LIMBS>: ArrayEncoding,

Source§

fn from(fe: &MontyFieldElement<MOD, LIMBS>) -> Self

Converts to this type from the input type.
Source§

impl<MOD, const LIMBS: usize> From<MontyFieldElement<MOD, LIMBS>> for MontyFieldBytes<MOD, LIMBS>
where MOD: MontyFieldParams<LIMBS>, Uint<LIMBS>: ArrayEncoding,

Source§

fn from(fe: MontyFieldElement<MOD, LIMBS>) -> Self

Converts to this type from the input type.