From 4d0bfa2a5278f03110dbee2d44b2d4f3a10e5033 Mon Sep 17 00:00:00 2001 From: greg Date: Sun, 11 Feb 2018 16:45:26 -0800 Subject: [PATCH] Don't need clone() here --- src/schala_lang/parsing.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/schala_lang/parsing.rs b/src/schala_lang/parsing.rs index a8e5053..7892aa0 100644 --- a/src/schala_lang/parsing.rs +++ b/src/schala_lang/parsing.rs @@ -183,7 +183,7 @@ fn handle_alphabetic(c: char, input: &mut CharIter) -> TokenType { } match KEYWORDS.get(buf.as_str()) { - Some(kw) => TokenType::Keyword(kw.clone()), + Some(kw) => TokenType::Keyword(*kw), None => TokenType::Identifier(Rc::new(buf)), } }