Hacker News new | past | comments | ask | show | jobs | submit login

Using a language that eschews state to try and process the state in a modal editor tickles me.



To elaborate on the other reply, Haskell actually takes a very in-depth and principled approach to managing state. State is necessary for many applications, so rather than eschew it entirely, the idea is to isolate it and make it as explicit as possible. Frequently in complex stateful applications this is done by use of the State monad, with lenses to handle mutation of that state. There's a lot of theory behind it, but in practice it ends up being pretty similar in difficulty level to managing state in more popular languages, just a hell of a lot safer.


I know others have said it, but I would like to echo the "please don't say that Haskell eschews state" message :)


It doesn't. You can't run a program made of only pure functions. What it does it manage it.


Parsing and lexing in Haskell is one of its shining glories.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: