highway/
key.rs

1use core::ops::Index;
2
3/// Key used in `HighwayHash` that will drastically change the hash outputs.
4#[derive(Debug, Default, Clone, Copy)]
5#[repr(align(32))]
6pub struct Key(pub [u64; 4]);
7
8impl Index<usize> for Key {
9    type Output = u64;
10    fn index(&self, index: usize) -> &u64 {
11        &self.0[index]
12    }
13}