Skip to content

Commit

Permalink
upgrade to Rust v1.48.0 (pantsbuild#11210)
Browse files Browse the repository at this point in the history
Upgrade to Rust v1.48.0.  https://blog.rust-lang.org/2020/11/19/Rust-1.48.html

- Disabled `clippy::manual_strip` which is triggered now in code generated by the macros in the `cpython` crate.
- Disabled `clippy::rc_buffer` in code that put a `Vec<PathStat>` in an `Arc`.
  • Loading branch information
Tom Dyas authored Nov 21, 2020
1 parent 6b79455 commit 009d8bf
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 7 deletions.
2 changes: 1 addition & 1 deletion rust-toolchain
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.47.0
1.48.0
1 change: 1 addition & 0 deletions src/rust/engine/src/externs/fs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
// File-specific allowances to silence internal warnings of `py_class!`.
#![allow(
unused_braces,
clippy::manual_strip,
clippy::used_underscore_binding,
clippy::transmute_ptr_to_ptr,
clippy::zero_ptr
Expand Down
1 change: 1 addition & 0 deletions src/rust/engine/src/externs/interface.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
// File-specific allowances to silence internal warnings of `py_class!`.
#![allow(
unused_braces,
clippy::manual_strip,
clippy::used_underscore_binding,
clippy::transmute_ptr_to_ptr,
clippy::zero_ptr
Expand Down
3 changes: 3 additions & 0 deletions src/rust/engine/src/nodes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1436,6 +1436,9 @@ pub enum NodeOutput {
DirectoryListing(Arc<DirectoryListing>),
LinkDest(LinkDest),
ProcessResult(Box<ProcessResult>),
// Allow clippy::rc_buffer due to non-trivial issues that would arise in using the
// suggested Arc<[PathStat]> type. See https://github.com/rust-lang/rust-clippy/issues/6170
#[allow(clippy::rc_buffer)]
Paths(Arc<Vec<PathStat>>),
Value(Value),
}
Expand Down
6 changes: 3 additions & 3 deletions src/rust/engine/testutil/mock/src/action_cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ clippy::unseparated_literal_suffix,
#![allow(clippy::match_ref_pats)]
// Subjective style.
#![allow(
clippy::len_without_is_empty,
clippy::redundant_field_names,
clippy::too_many_arguments
clippy::len_without_is_empty,
clippy::redundant_field_names,
clippy::too_many_arguments
)]
// Default isn't as big a deal as people seem to think it is.
#![allow(clippy::new_without_default, clippy::new_ret_no_self)]
Expand Down
6 changes: 3 additions & 3 deletions src/rust/engine/workunit_store/src/metrics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ clippy::unseparated_literal_suffix,
#![allow(clippy::match_ref_pats)]
// Subjective style.
#![allow(
clippy::len_without_is_empty,
clippy::redundant_field_names,
clippy::too_many_arguments
clippy::len_without_is_empty,
clippy::redundant_field_names,
clippy::too_many_arguments
)]
// Default isn't as big a deal as people seem to think it is.
#![allow(clippy::new_without_default, clippy::new_ret_no_self)]
Expand Down

0 comments on commit 009d8bf

Please sign in to comment.