Skip to content

Commit

Permalink
Fix Clippy warnings on Rust 1.84 (#1216)
Browse files Browse the repository at this point in the history
Rust 1.84 has just released and with it, new clippy lints have been
added.

We're also updating to Rust 1.84 explicitly rather than returning to
stable to avoid the issues we had with the most recent release

### Does this change impact existing behavior?

No

### Does this change need a changelog entry?

No

---

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license and I agree to the terms of
the [Developer Certificate of Origin
(DCO)](https://developercertificate.org/).

---------

Signed-off-by: Simon Beal <[email protected]>
  • Loading branch information
muddyfish authored Jan 13, 2025
1 parent 7d6e8f9 commit 19d06e2
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion mountpoint-s3-client/src/instance_info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ fn retrieve_instance_identity_document() -> Result<IdentityDocument, InstanceInf

fn imds_disabled() -> bool {
match env::var_os("AWS_EC2_METADATA_DISABLED") {
Some(val) => val.to_ascii_lowercase() != "false",
Some(val) => !val.eq_ignore_ascii_case("false"),
None => false,
}
}
Expand Down
2 changes: 1 addition & 1 deletion mountpoint-s3/tests/fuse_tests/cache_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ fn get_random_key(key_prefix: &str, key_suffix: &str, min_size_in_bytes: usize)
let random_suffix: u64 = rand::thread_rng().gen();
let last_key_part = format!("{key_suffix}{random_suffix}"); // part of the key after all the "/"
let full_key = format!("{key_prefix}{last_key_part}");
let full_key_size = full_key.as_bytes().len();
let full_key_size = full_key.len();
let padding_size = min_size_in_bytes.saturating_sub(full_key_size);
let padding = "0".repeat(padding_size);
format!("{last_key_part}{padding}")
Expand Down
2 changes: 1 addition & 1 deletion rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[toolchain]
channel = "1.83"
channel = "1.84"
components = ["rust-src"]

0 comments on commit 19d06e2

Please sign in to comment.