You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "emilk (via GitHub)" <gi...@apache.org> on 2026/08/04 19:08:38 UTC
[PR] More workspace lints: finish `[workspace.lints.rust]` [arrow-rs]
emilk opened a new pull request, #10551:
URL: https://github.com/apache/arrow-rs/pull/10551
# Which issue does this PR close?
No issue in particular
- Follow-up to #10533
- Related to #10458
# Rationale for this change
#10533 added `[workspace.lints]` with a minimal set of lints. This fills out `[workspace.lints.rust]` with the rest of the lints from [egui's `Cargo.toml`](https://github.com/emilk/egui/blob/main/Cargo.toml), one lint per commit.
# What changes are included in this PR?
Enables `explicit_outlives_requirements`, `trivial_numeric_casts`, `unexpected_cfgs`, `unused_extern_crates` and `unused_lifetimes`, and records the four that are deliberately left off (`elided_lifetimes_in_paths`, `trivial_casts`, `unused_qualifications` as too noisy; `unsafe_code` does not apply here).
The only hand-written code that changed: 13 identity casts (`u64 as u64`), one unused lifetime parameter, and 54 dead `extern crate` lines in benches and examples. Violations in the flatbuffers-generated `arrow-ipc/src/gen/` modules are allowed in `gen/mod.rs`, which `regen.sh` leaves alone.
# Are these changes tested?
Yes, by existing CI. `cargo clippy --workspace --all-targets --all-features` is at zero warnings, and the nightly docs job is clean.
# Are there any user-facing changes?
No public API changed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] More workspace lints: finish `[workspace.lints.rust]` [arrow-rs]
Posted by "Jefffrey (via GitHub)" <gi...@apache.org>.
Jefffrey commented on code in PR #10551:
URL: https://github.com/apache/arrow-rs/pull/10551#discussion_r3716961490
##########
parquet/src/arrow/array_reader/primitive_array.rs:
##########
@@ -671,6 +671,8 @@ mod tests {
;
// create expected array as primitive, and cast to result type
+ // The cast is a no-op when the source and result types are the same.
+ #[allow(trivial_numeric_casts)]
Review Comment:
```suggestion
#[expect(trivial_numeric_casts)]
```
##########
parquet/src/util/bit_util.rs:
##########
@@ -93,6 +93,8 @@ macro_rules! from_bitpacked {
const BATCH_SIZE: usize = std::mem::size_of::<$ty>() * 8;
#[inline]
+ // The cast is a no-op when `$ty` is `u64`.
+ #[allow(trivial_numeric_casts)]
Review Comment:
```suggestion
#[expect(trivial_numeric_casts)]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] More workspace lints: finish `[workspace.lints.rust]` [arrow-rs]
Posted by "Jefffrey (via GitHub)" <gi...@apache.org>.
Jefffrey commented on PR #10551:
URL: https://github.com/apache/arrow-rs/pull/10551#issuecomment-5188732925
thanks @emilk
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] More workspace lints: finish `[workspace.lints.rust]` [arrow-rs]
Posted by "emilk (via GitHub)" <gi...@apache.org>.
emilk commented on code in PR #10551:
URL: https://github.com/apache/arrow-rs/pull/10551#discussion_r3718413514
##########
parquet/src/arrow/array_reader/primitive_array.rs:
##########
@@ -671,6 +671,8 @@ mod tests {
;
// create expected array as primitive, and cast to result type
+ // The cast is a no-op when the source and result types are the same.
+ #[allow(trivial_numeric_casts)]
Review Comment:
good call
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] More workspace lints: finish `[workspace.lints.rust]` [arrow-rs]
Posted by "Jefffrey (via GitHub)" <gi...@apache.org>.
Jefffrey merged PR #10551:
URL: https://github.com/apache/arrow-rs/pull/10551
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org