Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> first class effects

There's not really first class effects though, ultimately just IO.



They’re first class in the sense that they can be described, stored, computed, separated etc from pure functions. Fair to call them first class.


Koka has first class effects, but I think we have different interpretations of the statement above.

Could you please clarify what you mean by 'stored'?


Effect systems like effectful and Bluefin absolutely provide first class effects, ultimately not too dissimilar to Koka.


Okay, might be definitional, but when I think of 'first class', I think of something baked in to the language. So in Haskell's case, in the Prelude I suppose.


That's kind of the opposite of what functional programmers mean by "first class", or at least orthogonal. "Functions are first class" means that they don't have any special treatment, relative to other entities. They're not really a special "built-in" thing. You can just pass them around and operate on them like an other sorts of values.




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

Search: