lib.lists.init: rewrite to not call take

This commit is contained in:
Eman Resu
2026-06-24 18:29:21 -04:00
parent 09b8cbd5d9
commit 986cf9adb8
+1 -1
View File
@@ -1875,7 +1875,7 @@ rec {
init =
list:
assert lib.assertMsg (list != [ ]) "lists.init: list must not be empty!";
take (length list - 1) list;
genList (elemAt list) (length list - 1);
/**
Returns the image of the cross product of some lists by a function.