4 ms·
I think this is a really good idea -- many people, myself included, get really excited about Haskell and then are turned off by the complexity of monad transfor
by rjeli 9y ago
I think this is a really good idea -- many people, myself included, get really excited about Haskell and then are turned off by the complexity of monad transformers.
I would recommend that you focus on good error messages that explain monad-related errors in "user land" and not force them to either guess about what's wrong or suddenly learn all the stuff under the hood. It's a terrible experience and you see it in C++ with incomprehensible template errors or any kind of transpiled language like ClojureScript that gives you errors from the underlying implementation.
- wdanilo 9y agoThat is a very good point. We treat "monads" in a very special way in Luna - they have their own type section and we can analyse them and report errors much clearer than Haskell can for example. This does NOT mean that we limit them in any way. You are free to define your monads and convert them to ordinary types or back as you wish :) But we normally dont describe them as monads, just as "context", because it is easier to understand.