From 87f5930c3fb2c852f5243278b7a9da8e117d95e4 Mon Sep 17 00:00:00 2001 From: volth Date: Fri, 20 Jul 2018 17:56:59 +0000 Subject: [bot]: remove unreferenced code --- lib/generators.nix | 2 -- lib/lists.nix | 1 - lib/modules.nix | 1 - lib/tests/misc.nix | 4 ---- lib/types.nix | 1 - 5 files changed, 9 deletions(-) (limited to 'lib') diff --git a/lib/generators.nix b/lib/generators.nix index aa6759087031..f5faf7007860 100644 --- a/lib/generators.nix +++ b/lib/generators.nix @@ -19,8 +19,6 @@ let libStr = lib.strings; libAttr = lib.attrsets; - flipMapAttrs = flip libAttr.mapAttrs; - inherit (lib) isFunction; in diff --git a/lib/lists.nix b/lib/lists.nix index 231c2317c0c4..288882924fff 100644 --- a/lib/lists.nix +++ b/lib/lists.nix @@ -64,7 +64,6 @@ rec { */ foldl = op: nul: list: let - len = length list; foldl' = n: if n == -1 then nul diff --git a/lib/modules.nix b/lib/modules.nix index 20207b31d35b..a443d5ec5d16 100644 --- a/lib/modules.nix +++ b/lib/modules.nix @@ -670,7 +670,6 @@ rec { { config, options, ... }: let fromOpt = getAttrFromPath from options; - toOpt = getAttrFromPath to options; toOf = attrByPath to (abort "Renaming error: option `${showOption to}' does not exist."); in diff --git a/lib/tests/misc.nix b/lib/tests/misc.nix index eab20d0f14dc..3f2d742e7884 100644 --- a/lib/tests/misc.nix +++ b/lib/tests/misc.nix @@ -380,10 +380,6 @@ runTests { resRem7 = res6.replace (a: removeAttrs a ["a"]); - resReplace6 = let x = defaultOverridableDelayableArgs id { a = 7; mergeAttrBy = { a = builtins.add; }; }; - x2 = x.merge { a = 20; }; # now we have 27 - in (x2.replace) { a = 10; }; # and override the value by 10 - # fixed tests (delayed args): (when using them add some comments, please) resFixed1 = let x = defaultOverridableDelayableArgs id ( x: { a = 7; c = x.fixed.b; }); diff --git a/lib/types.nix b/lib/types.nix index cf6f2aa46e40..98eff2ac6ffb 100644 --- a/lib/types.nix +++ b/lib/types.nix @@ -309,7 +309,6 @@ rec { } else def; - listOnly = listOf elemType; attrOnly = attrsOf elemType; in mkOptionType rec { name = "loaOf"; -- cgit 1.4.1