File tree Expand file tree Collapse file tree 1 file changed +3
-15
lines changed Expand file tree Collapse file tree 1 file changed +3
-15
lines changed Original file line number Diff line number Diff line change @@ -36,11 +36,7 @@ fn (s State) to_bytes() []u8 {
36
36
for y in 0 .. 5 {
37
37
for x in 0 .. 5 {
38
38
unsafe {
39
- $if little_endian {
40
- binary.little_endian_put_u64_at (mut byte_array, s.a[x][y], index)
41
- } $else {
42
- binary.big_endian_put_u64_at (mut byte_array, s.a[x][y], index)
43
- }
39
+ binary.little_endian_put_u64_at (mut byte_array, s.a[x][y], index)
44
40
}
45
41
index + = 8
46
42
}
@@ -61,11 +57,7 @@ fn (mut s State) from_bytes(byte_array []u8) {
61
57
62
58
for y in 0 .. 5 {
63
59
for x in 0 .. 5 {
64
- $if little_endian {
65
- s.a[x][y] = binary.little_endian_u64_at (byte_array, index)
66
- } $else {
67
- s.a[x][y] = binary.big_endian_u64_at (byte_array, index)
68
- }
60
+ s.a[x][y] = binary.little_endian_u64_at (byte_array, index)
69
61
index + = 8
70
62
}
71
63
}
@@ -87,11 +79,7 @@ fn (mut s State) xor_bytes(byte_array []u8, rate int) {
87
79
88
80
for y in 0 .. 5 {
89
81
for x in 0 .. 5 {
90
- $if little_endian {
91
- s.a[x][y] ^= binary.little_endian_u64_at (byte_array, index)
92
- } $else {
93
- s.a[x][y] ^= binary.big_endian_u64_at (byte_array, index)
94
- }
82
+ s.a[x][y] ^= binary.little_endian_u64_at (byte_array, index)
95
83
index + = 8
96
84
97
85
if index > = rate {
You can’t perform that action at this time.
0 commit comments