From b7ee07d7f1e970df77873361a40e0a71e94b1e90 Mon Sep 17 00:00:00 2001 From: David Nadlinger Date: Fri, 22 Apr 2022 23:50:00 +0100 Subject: [PATCH] core/builtins: Simplify vector of None creation [nfc] --- nac3core/src/toplevel/builtins.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/nac3core/src/toplevel/builtins.rs b/nac3core/src/toplevel/builtins.rs index 1c1228fc..30001443 100644 --- a/nac3core/src/toplevel/builtins.rs +++ b/nac3core/src/toplevel/builtins.rs @@ -1265,8 +1265,7 @@ pub fn get_builtins(primitives: &mut (PrimitiveStore, Unifier)) -> BuiltinInfo { })), ]; - let ast_list: Vec>> = - (0..top_level_def_list.len()).map(|_| None).collect(); + let ast_list: Vec>> = vec![None; top_level_def_list.len()]; ( izip!(top_level_def_list, ast_list).collect_vec(), &[