summary refs log tree commit diff
path: root/lib/default.nix
diff options
context:
space:
mode:
authorAdam Joseph <adam@westernsemico.com>2023-08-14 02:47:59 +0300
committerArtturin <Artturin@artturin.com>2023-08-14 02:50:32 +0300
commita1fdbae706c846f01c31bbe02cb8246fa348b480 (patch)
treea6b5eca09c67592a15c211cfc3f3d25f225166f5 /lib/default.nix
parentb5f77af42cf760e6d4b44015c6e7bb36938e56ab (diff)
downloadnixpkgs-a1fdbae706c846f01c31bbe02cb8246fa348b480.tar
nixpkgs-a1fdbae706c846f01c31bbe02cb8246fa348b480.tar.gz
nixpkgs-a1fdbae706c846f01c31bbe02cb8246fa348b480.tar.bz2
nixpkgs-a1fdbae706c846f01c31bbe02cb8246fa348b480.tar.lz
nixpkgs-a1fdbae706c846f01c31bbe02cb8246fa348b480.tar.xz
nixpkgs-a1fdbae706c846f01c31bbe02cb8246fa348b480.tar.zst
nixpkgs-a1fdbae706c846f01c31bbe02cb8246fa348b480.zip
lib.customisation: add uncurried form of makeScopeWithSplicing
Deeply-curried functions are pretty error-prone in untyped languages
like Nix.  This is a particularly bad case because
`top-level/splice.nix` *also* declares a makeScopeWithSplicing, but
it takes *two fewer arguments*.

Let's add a version that uses attrset-passing form, to provide some
minimal level of sanity-checking.

This also provides defaults for keep and extra (these are often
unneeded by the user).
Diffstat (limited to 'lib/default.nix')
-rw-r--r--lib/default.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/default.nix b/lib/default.nix
index 73b8ad87154..1958d93aaf5 100644
--- a/lib/default.nix
+++ b/lib/default.nix
@@ -112,7 +112,7 @@ let
       noDepEntry fullDepEntry packEntry stringAfter;
     inherit (self.customisation) overrideDerivation makeOverridable
       callPackageWith callPackagesWith extendDerivation hydraJob
-      makeScope makeScopeWithSplicing;
+      makeScope makeScopeWithSplicing makeScopeWithSplicing';
     inherit (self.derivations) lazyDerivation;
     inherit (self.meta) addMetaAttrs dontDistribute setName updateName
       appendToName mapDerivationAttrset setPrio lowPrio lowPrioSet hiPrio