lispy
lispy copied to clipboard
Attempt to detect impure functions
Pure functions are functions that always have the same result for a given input. This implicitly means that all functions that don't make system calls are pure (as system calls allow IO, time references, randomness, etc).
I would be interesting to me to detect when code did things like this. There are a few features that could build off of such a system
- Invalidate memoization / don't memoize none pure functions
- Monads / Forcing functions that do IO to ask permission.
- Deterministic debugging / profiling?
http://fixunix.com/unix/353470-intercepting-system-calls-linux.html
http://my.safaribooksonline.com/0131774298/ch05lev1sec4?portal=adobepress