]> git.lizzy.rs Git - rust.git/blobdiff - src/tools/tidy/src/primitive_docs.rs
Rollup merge of #94839 - TaKO8Ki:suggest-using-double-colon-for-struct-field-type...
[rust.git] / src / tools / tidy / src / primitive_docs.rs
index 8476650d9b5f726e0c2884add732f8667859cbdd..f3200e0afd71a88bd543fd8f9dd84b01dc0b313e 100644 (file)
@@ -8,10 +8,10 @@ pub fn check(library_path: &Path, bad: &mut bool) {
     let std_name = "std/src/primitive_docs.rs";
     let core_name = "core/src/primitive_docs.rs";
     let std_contents = std::fs::read_to_string(library_path.join(std_name))
-        .unwrap_or_else(|e| panic!("failed to read library/{}: {}", std_name, e));
+        .unwrap_or_else(|e| panic!("failed to read library/{std_name}: {e}"));
     let core_contents = std::fs::read_to_string(library_path.join(core_name))
-        .unwrap_or_else(|e| panic!("failed to read library/{}: {}", core_name, e));
+        .unwrap_or_else(|e| panic!("failed to read library/{core_name}: {e}"));
     if std_contents != core_contents {
-        tidy_error!(bad, "library/{} and library/{} have different contents", core_name, std_name);
+        tidy_error!(bad, "library/{core_name} and library/{std_name} have different contents");
     }
 }