Skip to content

Adopt Cargo 1.97 warning policy and close toolchain audit gaps #189

Description

@acgetchell

Summary

Complete the Rust/Cargo 1.97 tooling audit that followed the MSRV upgrade in #174 and PR #183. Evaluate Cargo's new cache-friendly warning policy, explicitly close the remaining symbol-mangling and linker-message questions, and record no-change conclusions for unrelated 1.97 features.

This is post-v0.4.4 tooling follow-up. It does not change the published API, numerical behavior, MSRV, or v0.4.4 artifacts, and it does not require an immediate patch release.

Current state

  • Cargo.toml already denies Rust warnings through [lints.rust].
  • Benchmark compilation in justfile still uses RUSTFLAGS='-D warnings', which can invalidate Cargo build caches.
  • Documentation builds use RUSTDOCFLAGS='-D warnings'; Cargo's new build-warning policy is not a replacement for rustdoc lint enforcement.
  • No current source, benchmark, or support script was found parsing legacy Rust symbol names.
  • The Rust 1.97 upgrade passed Linux, macOS, and Windows CI, but the symbol-mangling and linker_messages conclusions were not recorded explicitly.

Proposed work

  • Evaluate Cargo 1.97's build.warnings = "deny" configuration or CARGO_BUILD_WARNINGS=deny for benchmark/build validation currently using RUSTFLAGS='-D warnings'.
    • Preserve strict warnings for local crate targets.
    • Preserve the separate RUSTDOCFLAGS='-D warnings' documentation contract.
    • Confirm that any replacement improves cache reuse and does not weaken feature or benchmark-target coverage.
  • Confirm that default v0 symbol mangling requires no repository change because no tooling depends on legacy symbol names. If profiling or symbol-processing assumptions are discovered, update them and add focused validation.
  • Inspect supported-platform output for the new linker_messages lint. Fix real linker diagnostics; allow only demonstrated false positives and scope any suppression narrowly.
  • Record whether Cargo's resolver.lockfile-path provides a concrete benefit to release benchmarking, historical checkout, or read-only-source workflows. Prefer an explicit no-change conclusion over speculative configuration.
  • Record the already-observed no-change conclusions for Result<_, Infallible> must-use behavior and RepeatN::default, which do not materially intersect the current crate.

Acceptance criteria

  • Applicable RUSTFLAGS='-D warnings' build/benchmark usage is replaced with Cargo 1.97 warning policy, or retained with a concrete reason.
  • Rustdoc warning enforcement remains intact.
  • Benchmark compilation remains strict across the normal and exact feature surfaces.
  • Symbol-mangling impact is documented as no-change or addressed with focused validation.
  • Linux, macOS, and Windows linker-message behavior is reviewed; real warnings are fixed and any suppression is narrowly justified.
  • resolver.lockfile-path, Infallible must-use behavior, and RepeatN::default receive explicit adopt/no-change conclusions.
  • Repository validation passes without changing numerical results, published APIs, or the Rust 1.97.0 MSRV.

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationenhancementNew feature or requestperformancePerformance related issuesrustPull requests that update rust codevalidation

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions