Type-check acyclic-fs on aarch64 Linux and widen nlink losslessly

Merged
VA
3d ago
+23-2

Problem

Cloud found acyclic-fs fails to compile on aarch64 Linux: rust/crates/filesystem/src/native_host/stat.rs:86 and :165, E0308. libc nlink_t is u32 on aarch64 and u64 on x86_64. SDK CI never compiles for arm, so it reached main.

Fix

  • A generic lossless<T, U: From<T>> helper (Linux only) for both sites. It is lossless on each width and never a same-type From (no clippy useless_conversion, no as).
  • New SDK aarch64 Linux check job in SDK Static on the free ubuntu-24.04-arm runner (public repo): cargo check --locked -p acyclic-fs --lib --features s3-http.

Tests run

  • bb1 x86_64: cargo check --locked -p acyclic-fs --lib --features s3-http passes. Its only warning is the pre-existing unused generation_from_head_record_value on main.
  • aarch64: proven by this PR's new CI job.

šŸ¤– Generated with Claude Code


Summary by cubic

Fixes acyclic-fs failing to compile on aarch64 Linux, where libc's nlink_t is u32 rather than u64.

  • HostStat::nlink and from_statx in stat.rs used width-specific libc types that only compiled on x86_64.
  • A Linux-only generic lossless helper converts via From<T>, which is lossless on both widths and avoids same-type conversions or as casts.
  • Adds an SDK aarch64 Linux check job to static.yml on the ubuntu-24.04-arm runner and admits that runner in scripts/check-workflow-runners.mjs so a width-dependent break can't reach main again.