diff --git a/build.rs b/build.rs index 307b9f46..6cd48387 100644 --- a/build.rs +++ b/build.rs @@ -14,7 +14,7 @@ use walkdir::WalkDir; fn main() { let out_dir = env::var("OUT_DIR").unwrap(); let destination = Path::new(&out_dir).join("tests.rs"); - let mut test_file = File::create(&destination).unwrap(); + let mut test_file = File::create(destination).unwrap(); // Re-generate the tests if any org-mode files change println!("cargo:rerun-if-changed=org_mode_samples"); @@ -51,7 +51,7 @@ fn write_test(test_file: &mut File, test: &walkdir::DirEntry) { .to_lowercase() .strip_suffix(".org") .expect("Should have .org extension") - .replace("/", "_"); + .replace('/', "_"); write!( test_file,