From 7c617f524b1741a6a472ee811176fbab40961921 Mon Sep 17 00:00:00 2001 From: Michael Gehring Date: Fri, 6 Feb 2015 16:41:20 +0100 Subject: [PATCH] Fix closure syntax --- src/fmt/parasplit.rs | 2 +- src/hashsum/hashsum.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/fmt/parasplit.rs b/src/fmt/parasplit.rs index bfde0ecfd..a905e1f0d 100644 --- a/src/fmt/parasplit.rs +++ b/src/fmt/parasplit.rs @@ -535,7 +535,7 @@ impl<'a> Iterator for WordSplit<'a> { let mut word_nchars = 0; self.position = match self.string[word_start..] - .find(|&mut: x: char| if !x.is_whitespace() { word_nchars += char_width(x); false } else { true }) { + .find(|x: char| if !x.is_whitespace() { word_nchars += char_width(x); false } else { true }) { None => self.length, Some(s) => s + word_start }; diff --git a/src/hashsum/hashsum.rs b/src/hashsum/hashsum.rs index ee3c4923f..2688ccb6c 100644 --- a/src/hashsum/hashsum.rs +++ b/src/hashsum/hashsum.rs @@ -72,7 +72,7 @@ fn detect_algo(program: &str, matches: &getopts::Matches) -> (&'static str, Box< "sha512sum" => ("SHA512", Box::new(Sha512::new()) as Box), _ => { { - let mut set_or_crash = |&mut: n, val| -> () { + let mut set_or_crash = |n, val| -> () { if alg.is_some() { crash!(1, "You cannot combine multiple hash algorithms!") }; name = n; alg = Some(val);