mirror of
https://github.com/NixOS/nix.git
synced 2024-11-22 23:02:27 +00:00
12 lines
261 B
Nix
12 lines
261 B
Nix
with import ./lib.nix;
|
|
|
|
let
|
|
|
|
attrs = {y = "y"; x = "x"; foo = "foo";} // rec {x = "newx"; bar = x;};
|
|
|
|
names = builtins.attrNames attrs;
|
|
|
|
values = map (name: builtins.getAttr name attrs) names;
|
|
|
|
in assert values == builtins.attrValues attrs; concat values
|