Comment

Comment by nerdtime

>You're just trolling at this point. Please reconsider your confidence in this material, because you are egregiously mistaken.

Why the heck would I run such a long expose and troll you and be mistaken at the same time.

>How does this Haskell program write to stdout if it doesn't mutate memory?

Let's not be stupid here. Every program on the face of the earth must mutate memory because that's how computers work. Assembly instructions mutate things. We're not even talking about that. We're talking about application level programming where we only deal with primitives that the application programmer is aware about. I am saying that at the application level within the category of Hask nothing is mutated.

In your example tell me what haskell primitive.... What variable or data was mutated within haskell? That is what I'm referring to.

Try to implement IO or ST in another lang using only purely functional primitives. Use your algebra to make it work. You'll find it's impossible. What this means is that imperative primitives must exist for any programming to work.

>Then it doesn't work. Every Haskell program does nothing, because mutation of program state does not occur.

Obviously I'm operating on a certain layer of abstraction here. In X = 6, X is obviously immutable in haskell. A runtime is obviously executing your haskell program and mutating the console but your haskell code itself is pure. But you know this. It's quite obvious you're the one that's trolling.

parent nerdtime 6 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton