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

In my experience, it is rare to want to put logging in pure code in the first place. You tend to already be using some kind of monad or IO facility in the places where you would naturally want to put logging. This is from my experience with Haskell.


That's my experience too. The only reason you may want to log something is because there's something that may change on different executions of the same code, what means it is not pure.

That kind of mixing is common on languages that are not completely pure. Because people do not have a good idea about what code depends on the real world, and tend to get "pure" code that can not be relied to be actually pure.




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

Search: