Skip to content

Instantly share code, notes, and snippets.

@shlevy
Created March 3, 2018 06:33
Show Gist options
  • Select an option

  • Save shlevy/4ca717d8b59afe38a7aa70558abdb997 to your computer and use it in GitHub Desktop.

Select an option

Save shlevy/4ca717d8b59afe38a7aa70558abdb997 to your computer and use it in GitHub Desktop.
lib: let inherit (lib) extrec; in
{ testSimpleExtrec =
{ expr =
let base = extrec."{"{ x = 123;
y = self: self.x;
}"}";
overrides = extrec."{"{ x = 456;
z = self: self.y;
}"}";
in extrec.fix (extrec.merge base overrides);
expected = { x = 456; y = 456; z = 456; };
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment