mirror of
https://github.com/sharkdp/hyperfine.git
synced 2026-11-01 08:50:19 +00:00
style: simplify string interpolation
This commit is contained in:
1 parent
e8ff88dad1
commit
ef1263279d
13 files changed
+30
-33
No files matched your search
+2
-2
@@ -108,7 +108,7 @@ impl ExportManager {
|
||||
ExportTarget::Stdout
|
||||
} else {
|
||||
let _ = File::create(filename)
|
||||
.with_context(|| format!("Could not create export file '{}'", filename))?;
|
||||
.with_context(|| format!("Could not create export file '{filename}'"))?;
|
||||
ExportTarget::File(filename.to_string())
|
||||
},
|
||||
});
|
||||
@@ -153,5 +153,5 @@ impl ExportManager {
|
||||
fn write_to_file(filename: &str, content: &[u8]) -> Result<()> {
|
||||
let mut file = OpenOptions::new().write(true).open(filename)?;
|
||||
file.write_all(content)
|
||||
.with_context(|| format!("Failed to export results to '{}'", filename))
|
||||
.with_context(|| format!("Failed to export results to '{filename}'"))
|
||||
}
|
||||
Reference in new issue
Block a user