Repository navigation
chore: make clippy and the lib tests pass on the declared minimum Rust - #1679
Merged
Merged
Conversation
Cargo.toml declares rust-version 1.89 and CI runs stable, which is newer. On 1.90 clippy reported three lints and the test target did not compile, so a contributor on the supported minimum could not run either. No CI job builds the minimum, which is why it went unnoticed. - owned_end.rs: !x.is_some_and(f) becomes x.is_none_or(!f), same meaning. - console_shim_macos.rs, dir_fd.rs: allow the lint with the reason beside it; the compile-time assert and the per-Unix integer widths are the point. - commands.test.rs: compare Vec<PathBuf> with Vec<PathBuf>. String against PathBuf only compiles on a newer standard library. Verified with clippy --all-targets -D warnings and the lib tests on both 1.90 and 1.99. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
3 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Cargo.tomldeclaresrust-version = "1.89"and CI runsstable(1.99). On 1.90,clippy --all-targets -D warningsreported three lints and the test target did not compile, so anyone on the supported minimum could run neither. No CI job builds the minimum, so nothing noticed.What Changed
agent_journal/admission/owned_end.rs:!x.is_some_and(f)becomesx.is_none_or(!f)(same meaning; stable since 1.82).browser/console_shim_macos.rs:#[allow(clippy::assertions_on_constants)]on the compile-time pin whose point is the constant.workflow/dir_fd.rs:#[allow(clippy::unnecessary_cast)]onholds, with the reason on the line (dev_tisi32on macOS, so the casts are needed somewhere). Placed on the function so the file stays at exactly 300 lines.window_manager/commands.test.rs: compareVec<PathBuf>withVec<PathBuf>.String == PathBufonly compiles on a newer standard library.Validation
cargo clippy --all-targets -- -D warnings: clean on 1.90 and on 1.99cargo fmt --check,pnpm check:predelta(50 gates)cargo test --libon 1.90 and on 1.99: 5274 passed, 4 failed in both. The four arekvo::native_tests(WebKit, macOS): they fail in a full parallel run on this machine on either toolchain, pass alone (4/4), and pass in CI's macOS job.🤖 Generated with Claude Code