From f77d51cfa50df2895dda9ad7b860a8fb407e8391 Mon Sep 17 00:00:00 2001 From: gwenn Date: Mon, 27 May 2019 19:46:08 +0200 Subject: [PATCH] Rustfmt --- src/tty/unix.rs | 8 +++++--- src/undo.rs | 3 ++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/tty/unix.rs b/src/tty/unix.rs index 8efe73cd62..df87dc23e5 100644 --- a/src/tty/unix.rs +++ b/src/tty/unix.rs @@ -667,9 +667,11 @@ fn read_digits_until(rdr: &mut RawReader, sep: char) -> Result { loop { match rdr.next_char()? { digit @ '0'..='9' => { - num = num.saturating_mul(10).saturating_add(digit.to_digit(10).unwrap()); - continue - }, + num = num + .saturating_mul(10) + .saturating_add(digit.to_digit(10).unwrap()); + continue; + } c if c == sep => break, _ => return Err(error::ReadlineError::from(io::ErrorKind::InvalidData)), } diff --git a/src/undo.rs b/src/undo.rs index 8eadfa899c..3addd0a7a2 100644 --- a/src/undo.rs +++ b/src/undo.rs @@ -121,7 +121,8 @@ impl Changeset { mark } - /// Returns `true` when changes happen between the last call to `begin` and this `end`. + /// Returns `true` when changes happen between the last call to `begin` and + /// this `end`. pub fn end(&mut self) -> bool { debug!(target: "rustyline", "Changeset::end"); self.redos.clear();