mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-05 13:23:17 +00:00
997e54a4fb
We also renamed `filter` (as a name of a parameter) to `predicate` following the naming suggestion in code review. It's better! Since it's not part of an attrset, the name can change with no impact to semantics, since it can't be observed with `builtins.functionArgs`. ``` $ nix-repl Nix 2.21.0 Type :? for help. nix-repl> f = x: y: z: (x + y + z) nix-repl> builtins.functionArgs f { } nix-repl> :doc builtins.functionArgs Synopsis: builtins.functionArgs f Return a set containing the names of the formal arguments expected by the function f. The value of each attribute is a Boolean denoting whether the corresponding argument has a default value. For instance, functionArgs ({ x, y ? 123}: ...) = { x = false; y = true; }. "Formal argument" here refers to the attributes pattern-matched by the function. Plain lambdas are not included, e.g. functionArgs (x: ...) = { }. ``` |
||
---|---|---|
.. | ||
default.nix |