[Nix-dev] Re: NixOS: New scheme - small explanation of fix

Ludovic Courtès ludo at gnu.org
Thu Nov 20 09:58:01 CET 2008


Hi,

Marc Weber <marco-oweber at gmx.de> writes:

> let attrs = {
>   a = 7;
>   b = func attrs ; # eg func = (a : a.a);
> }; in attrs
>
> now fix is an abstraction over the last style:
>
> fix ( attrs : {
>     a = 7;
>     b = func attrs
> });

OK, understood!  It's just that I'm not used to this mechanisms, and the
phrase "the fix style" sounded strange to me.  ;-)

(Maybe I'd have called it `fixpoint' or something to avoid confusion,
but maybe it's not the term Haskellers are used to.)

> I hope I've shed some light into fix usage for everyone who was scared
> when seeing the name until now (?)

Yes, thanks!

(Although I don't yet understand exactly how it relates to Nicolas'
post...)

Ludo'.




More information about the nix-dev mailing list