diff --git a/parser/src/cfg/mod.rs b/parser/src/cfg/mod.rs index 06dcec65d..39e983ea1 100755 --- a/parser/src/cfg/mod.rs +++ b/parser/src/cfg/mod.rs @@ -1093,7 +1093,7 @@ fn parse_layer_indexes( let mut cfg_third = 0; if let Some(third) = subexprs.peek() { if let Some(third_list) = third.list(None) { - if third_list.len() > 0 { + if !third_list.is_empty() { if let Some(third_list_1st_s) = &third_list[0].atom(None) { if DEFLAYER_ICON.iter().any(|&i| i == *third_list_1st_s) { cfg_third = 1; @@ -1429,11 +1429,7 @@ fn parse_action_as_cfg(expr: &SExpr) -> bool { if !DEFLAYER_ICON.iter().any(|&i| i == *expr_list_1st) { return false; } else { - if expr_list[1].atom(None).is_some() { - return true; - } else { - return false; - } + return expr_list[1].atom(None).is_some(); } } }