From c405ac9bd5b6e34fca1d743949992b605a15d13e Mon Sep 17 00:00:00 2001 From: Justin Worthe Date: Sun, 2 Sep 2018 09:29:14 +0200 Subject: Clippy suggested improvements --- src/engine/command.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/engine/command.rs') diff --git a/src/engine/command.rs b/src/engine/command.rs index b34553f..76cfaee 100644 --- a/src/engine/command.rs +++ b/src/engine/command.rs @@ -20,7 +20,7 @@ impl fmt::Display for Command { } impl Command { - pub fn cant_build_yet(&self, energy: u16) -> bool { + pub fn cant_build_yet(self, energy: u16) -> bool { use self::Command::*; match self { @@ -52,7 +52,7 @@ impl BuildingType { if id <= 4 && id != 3 { Some(unsafe { mem::transmute(id) }) } else { None } } - pub fn cant_build_yet(&self, energy: u16) -> bool { + pub fn cant_build_yet(self, energy: u16) -> bool { use self::BuildingType::*; let required = match self { -- cgit v1.2.3