Skip to content

Commit 9392ee5

Browse files
committed
Fix some new Clippy complaints
1 parent d200084 commit 9392ee5

2 files changed

Lines changed: 2 additions & 6 deletions

File tree

crates/xdv/src/lib.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -250,11 +250,7 @@ impl<T: XdvEvents> XdvParser<T> {
250250
if n_in_buffer != 0 && n_consumed == 0 {
251251
// We're going to need a bigger buffer in order to handle whatever
252252
// we're reading. Let's double it.
253-
let len = buf.len();
254-
buf.reserve(len);
255-
unsafe {
256-
buf.set_len(2 * len);
257-
}
253+
buf.resize(2 * buf.len(), 0);
258254
}
259255

260256
if n_read == 0 {

src/driver.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1550,7 +1550,7 @@ impl ProcessingSession {
15501550
status.note_highlighted(
15511551
"Writing ",
15521552
&format!("`{}`", real_path.display()),
1553-
&format!(" ({})", byte_len.get_appropriate_unit(true).to_string()),
1553+
&format!(" ({})", byte_len.get_appropriate_unit(true)),
15541554
);
15551555

15561556
let mut f = File::create(&real_path)?;

0 commit comments

Comments
 (0)