2 ms·
I think you can achieve the goal oriented style in Haskell. I am relatively new to Haskell but I think it can be done using MaybeT IO. In other words actions t
by bbcbasic 11y ago
I think you can achieve the goal oriented style in Haskell.
I am relatively new to Haskell but I think it can be done using MaybeT IO. In other words actions that perform IO but with a additional 'transformer' that allows them to 'fail' and abort further execution. As complicated as it sounds, it results in quite simple looking code similar to what is shown in that article for Icon.
Monads in general are sometimes refered to as a programmable semicolon, because you can change the nature of how one statement is bound to the next, with quite an amazing degree of flexibility.