-
Notifications
You must be signed in to change notification settings - Fork 253
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added support for kupyna512 hash #597
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please migrate this code to the digest
traits (see other crates in this repository for examples). The final crate should not contain any heap allocations and should be no_std
-compatible (i.e. you neeed to add #![no_std]
to lib.rs).
#[test] | ||
fn test_add_constant_xor() { | ||
let input = [ | ||
0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can use the hex-literal
crate for such constants (add it to dev-dependencies
).
} | ||
|
||
fn matrix_to_block(matrix: Matrix) -> Vec<u8> { | ||
let mut block = vec![0u8; ROWS * COLS]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Heap allocation is not necessary here. You can use byte array instead.
No description provided.