You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

9 lines
272 B
Nix

let
list = [ { name = "foo"; value = 123; }
{ name = "bar"; value = 456; } ];
string = ''{"x": [1, 2, 3], "y": null}'';
in
{
ex0 = builtins.listToAttrs list == { foo = 123; bar = 456; };
ex1 = builtins.fromJSON string == { x = [ 1 2 3 ]; y = null; };
}