test(algo): gate the Linux-only hash test's helpers to Linux x86_64

`blocks` and `fnv` are only used by the harris/describe hash test, which runs
on Linux x86_64 only, so on Windows they were dead code and `-D warnings`
failed the build.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Khawar Zamman WaniandClaude Opus 5.5 committed 2026-10-17 19:08:27 +05:30
1 parent 44406fa17e
commit 6bda896ad0
1 file changed
+2
+2
View File
@@ -701,10 +701,12 @@ mod parallel_tests {
}
/// Blocks of random brightness: lots of strong corners, no libm in the making.
#[cfg(all(target_os = "linux", target_arch = "x86_64"))]
fn blocks(w: usize, h: usize, seed: u64) -> Vec<f32> {
(0..w * h).map(|i| (mix(seed + ((i % w) / 8) as u64 * 4096 + ((i / w) / 8) as u64) >> 40) as f32 / 16_777_216.0).collect()
}
#[cfg(all(target_os = "linux", target_arch = "x86_64"))]
fn fnv(parts: &[u64]) -> u64 {
let mut h = 0xcbf2_9ce4_8422_2325u64;
for p in parts {