Skip to content

Commit

Permalink
Make Clippy happy
Browse files Browse the repository at this point in the history
  • Loading branch information
smoelius committed Oct 1, 2023
1 parent 91f13b8 commit bc8a336
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions cargo-test-fuzz/tests/third_party.rs
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ fn run_test(module_path: &str, test: &Test, no_run: bool) {
])
.logged_assert()
.success()
.stdout(predicate::str::is_match(r#"(?m)^[[:xdigit:]]{40}:"#).unwrap());
.stdout(predicate::str::is_match(r"(?m)^[[:xdigit:]]{40}:").unwrap());

Command::cargo_bin("cargo-test-fuzz")
.unwrap()
Expand Down Expand Up @@ -225,7 +225,7 @@ fn check_test_fuzz_dependency(subdir: &Path, test_package: &str) {
.packages
.iter()
.find(|package| package.name == test_package)
.unwrap_or_else(|| panic!("Could not find package `{}`", test_package));
.unwrap_or_else(|| panic!("Could not find package `{test_package}`"));
let dep = package
.dependencies
.iter()
Expand Down
2 changes: 1 addition & 1 deletion internal/src/dirs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ fn path_from_args_type<T>() -> String {
let type_name = type_name::<T>();
let n = type_name
.find("_fuzz")
.unwrap_or_else(|| panic!("unexpected type name: `{}`", type_name));
.unwrap_or_else(|| panic!("unexpected type name: `{type_name}`"));
type_name[..n].to_owned()
}

Expand Down
2 changes: 1 addition & 1 deletion macro/src/auto_concretize.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ mod functions {
|| Err(Kind::None),
|path| {
Ok(read_to_string(&path)
.unwrap_or_else(|_| panic!("`read_to_string` failed for `{:?}`", path)))
.unwrap_or_else(|_| panic!("`read_to_string` failed for `{path:?}`")))
},
)
}
Expand Down
6 changes: 3 additions & 3 deletions macro/src/mod_utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ fn contains(left: Span, right: Span) -> bool {
pub fn module_path(span: Span) -> Vec<Ident> {
let source = span.source_file();
let path = source.path();
let contents = read_to_string(&path)
.unwrap_or_else(|_| panic!("`read_to_string` failed for `{:?}`", path));
let contents =
read_to_string(&path).unwrap_or_else(|_| panic!("`read_to_string` failed for `{path:?}`"));
let file: File =
parse_str(&contents).unwrap_or_else(|_| panic!("Could not parse `{:?}` contents", source));
parse_str(&contents).unwrap_or_else(|_| panic!("Could not parse `{source:?}` contents"));
let mut visitor = ModVisitor {
target: span,
stack: Vec::new(),
Expand Down

0 comments on commit bc8a336

Please sign in to comment.