3 ms·
> The way I think about effectful computation and IO in Haskell is as a kind of enforced metaprogramming If you think of effectful computation in Haskell to be
by tome 2y ago
> The way I think about effectful computation and IO in Haskell is as a kind of enforced metaprogramming
If you think of effectful computation in Haskell to be a sort of metaprogramming, then indeed it will seem very complex, absurdly complex actually.
If you think of it as just the same as programming in any other language, except functions that do effects are tagged with a type that indicates that, then I think things will appear much simpler.
I prefer thinking of it as the latter, and it's been very effective (pun half intended) for me.