5 ms·
> when you can't toss a printf debug or log statement into a function without changing function signatures all the way up But you absolutely _can_ do this in H
by kchamplewski 7y ago
> when you can't toss a printf debug or log statement into a function without changing function signatures all the way up
But you absolutely _can_ do this in Haskell.
Sure, it's considered very unsafe and shouldn't be used in production, but for printf debugging it's fine.
Admittedly, production-ready logging requires type signature modification, but if you subscribe to Haskell's idea that side-effects should be reflected in type signatures, then I don't see that as excessive.
- carterschonwald 7y agoDebug.trace is handy and horrifying indeed :)