mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-09 19:13:26 +03:00
lib.types.anything: remove custom logic for lists (#340202)
This commit is contained in:
commit
d572d95502
4 changed files with 7 additions and 10 deletions
|
@ -253,12 +253,6 @@ rec {
|
|||
mergeFunction = {
|
||||
# Recursively merge attribute sets
|
||||
set = (attrsOf anything).merge;
|
||||
# Safe and deterministic behavior for lists is to only accept one definition
|
||||
# listOf only used to apply mkIf and co.
|
||||
list =
|
||||
if length defs > 1
|
||||
then throw "The option `${showOption loc}' has conflicting definitions, in ${showFiles (getFiles defs)}."
|
||||
else (listOf anything).merge;
|
||||
# This is the type of packages, only accept a single definition
|
||||
stringCoercibleSet = mergeOneOption;
|
||||
lambda = loc: defs: arg: anything.merge
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue