From 1c761a8e8bf924cf912d85a94e8edb084880cab8 Mon Sep 17 00:00:00 2001 From: Yaroslav Bolyukin Date: Sat, 12 Sep 2020 07:22:23 +0000 Subject: [PATCH] style: fix clippy lints --- --- a/crates/jrsonnet-evaluator/src/val.rs +++ b/crates/jrsonnet-evaluator/src/val.rs @@ -177,7 +177,7 @@ Func, } impl ValType { - pub fn name(&self) -> &'static str { + pub const fn name(&self) -> &'static str { use ValType::*; match self { Bool => "boolean", @@ -448,7 +448,7 @@ } } -fn is_function_like(val: &Val) -> bool { +const fn is_function_like(val: &Val) -> bool { matches!(val, Val::Func(_)) } -- gitstuff