From b5f5a1595d1508cc2b74aed4428f5844e1e070eb Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Fri, 17 Mar 2023 10:48:01 +0300 Subject: chore(tvix/eval): remove some dead code This was commented out and forgotten during the generator refactor, oh well. Change-Id: I474b685159a955a846db462da0dd0067af177b04 Reviewed-on: https://cl.tvl.fyi/c/depot/+/8321 Autosubmit: tazjin Reviewed-by: flokli Tested-by: BuildkiteCI --- tvix/eval/src/builtins/mod.rs | 31 ------------------------------- 1 file changed, 31 deletions(-) (limited to 'tvix/eval/src/builtins') diff --git a/tvix/eval/src/builtins/mod.rs b/tvix/eval/src/builtins/mod.rs index ba31d66b11d9..c56c53e46581 100644 --- a/tvix/eval/src/builtins/mod.rs +++ b/tvix/eval/src/builtins/mod.rs @@ -290,29 +290,6 @@ mod pure_builtins { } Ok(Value::List(out.into())) - // list.into_iter() - // .filter_map(|elem| { - // let result = match vm.call_with(&pred, [elem.clone()]) { - // Err(err) => return Some(Err(err)), - // Ok(result) => result, - // }; - - // // Must be assigned to a local to avoid a borrowcheck - // // failure related to the ForceResult destructor. - // let result = match result.force(vm) { - // Err(err) => Some(Err(vm.error(err))), - // Ok(value) => match value.as_bool() { - // Ok(true) => Some(Ok(elem)), - // Ok(false) => None, - // Err(err) => Some(Err(vm.error(err))), - // }, - // }; - - // result - // }) - // .collect::, _>>() - // .map(|list| Value::List(NixList::from(list))) - // .map_err(Into::into) } #[builtin("floor")] @@ -593,14 +570,6 @@ mod pure_builtins { out.insert(key, result); } - // let res = - // attrs - // .as_ref() - // .into_iter() - // .flat_map(|(key, value)| -> EvalResult<(NixString, Value)> { - // let value = vm.call_with(&f, [key.clone().into(), value.clone()])?; - // Ok((key.to_owned(), value)) - // }); Ok(Value::attrs(out.into())) } -- cgit 1.4.1