Switch to associated constant

This commit is contained in:
Jonathan Underwood 2021-12-23 12:30:43 -07:00 committed by GitHub
parent 9cf552e240
commit 5e6d0f1363
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -40,10 +40,10 @@ impl AlignedType {
pub fn zeroed() -> Self {
AlignedType([0u8; 16])
}
}
/// A static zeroed out AlignedType for use in static assignments of [AlignedType; _]
pub static ZERO_ALIGNED: AlignedType = AlignedType([0u8; 16]);
const ZERO: AlignedType = AlignedType([0u8; 16]);
}
#[cfg(all(feature = "std", not(rust_secp_no_symbol_renaming)))]
pub(crate) const ALIGN_TO: usize = mem::align_of::<AlignedType>();