about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorEvgeny Egorochkin <phreedom@yandex.ru>2013-08-22 10:06:43 +0300
committerEvgeny Egorochkin <phreedom@yandex.ru>2013-08-22 10:06:43 +0300
commitfcbc4fe9ffe55924e760dd163a428f95c109d2bf (patch)
treee18c5c7e7e71f8ea826b6d0bafe9645cf27624b7 /pkgs
parenta3f148ce96493fa320a947e7a134b417880ee987 (diff)
downloadnixlib-fcbc4fe9ffe55924e760dd163a428f95c109d2bf.tar
nixlib-fcbc4fe9ffe55924e760dd163a428f95c109d2bf.tar.gz
nixlib-fcbc4fe9ffe55924e760dd163a428f95c109d2bf.tar.bz2
nixlib-fcbc4fe9ffe55924e760dd163a428f95c109d2bf.tar.lz
nixlib-fcbc4fe9ffe55924e760dd163a428f95c109d2bf.tar.xz
nixlib-fcbc4fe9ffe55924e760dd163a428f95c109d2bf.tar.zst
nixlib-fcbc4fe9ffe55924e760dd163a428f95c109d2bf.zip
Deprecate lib.zip in favor of lib.zipAttrsWith.
Add deprecation trace message.
Nixos has been ported away from lib.zip in d705c0c3a4b84768907ade90b3f420d62db422a2.
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/lib/attrsets.nix2
-rw-r--r--pkgs/lib/types.nix2
2 files changed, 2 insertions, 2 deletions
diff --git a/pkgs/lib/attrsets.nix b/pkgs/lib/attrsets.nix
index f562a2f7df40..01d51779c809 100644
--- a/pkgs/lib/attrsets.nix
+++ b/pkgs/lib/attrsets.nix
@@ -246,7 +246,7 @@ rec {
 
   /* backward compatibility */
   zipWithNames = zipAttrsWithNames;
-  zip = zipAttrsWith;
+  zip = builtins.trace "lib.zip is deprecated, use lib.zipAttrsWith instead" zipAttrsWith;
 
 
   /* Does the same as the update operator '//' except that attributes are
diff --git a/pkgs/lib/types.nix b/pkgs/lib/types.nix
index b634cccc8c69..afd5ed5e17cd 100644
--- a/pkgs/lib/types.nix
+++ b/pkgs/lib/types.nix
@@ -117,7 +117,7 @@ rec {
       name = "attribute set of ${elemType.name}s";
       check = x: lib.traceValIfNot isAttrs x
         && fold (e: v: v && elemType.check e) true (lib.attrValues x);
-      merge = lib.zip (name: elemType.merge);
+      merge = lib.zipAttrsWith (name: elemType.merge);
       iter = f: path: set: lib.mapAttrs (name: elemType.iter f (path + "." + name)) set;
       fold = op: nul: set: fold (e: l: elemType.fold op l e) nul (lib.attrValues set);
       docPath = path: elemType.docPath (path + ".<name>");