News for hackers. Stuff that matters.
Re:My First Impressions of Nix by crubier on Monday June 19, 2023 @05:15AM (#36388956)
Memoization is state. As a functional programming maximalist myself, I know it hurts a little bit, but still, Caching/Memoization is statefulness.

That said, you are right that as a user of the system, that statefulness is abstracted from you and you don't have to worry about it (until some subtle caching bugs forces you to dive deep in the rabbit hole)

Re:My First Impressions of Nix by rgoulter on Monday June 19, 2023 @08:04AM (#36390079)
Reminds me of this more abstract perspective: you can draw an analogy between working the filesystem, and programming languages working with memory.

https://www.tweag.io/blog/2022-07-14-taming-unix-with-nix/

Re:My First Impressions of Nix by sanderjd on Monday June 19, 2023 @04:55PM (#36396340)
Yeah I really bumped on this. A cache is absolutely state. It is sufficient to say "a referentially transparent cache is a technique to store state while avoiding most of the drawbacks typical to storing state". This is already a big accomplishment! No need to also redefine the word "state" to make the technique seem even more magical than it is.
Re:My First Impressions of Nix by pxc on Monday June 19, 2023 @07:33PM (#36397780)
* * *