lispy icon indicating copy to clipboard operation
lispy copied to clipboard

Attempt to detect impure functions

Open adamhaney opened this issue 12 years ago • 1 comments

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

  1. Invalidate memoization / don't memoize none pure functions
  2. Monads / Forcing functions that do IO to ask permission.
  3. Deterministic debugging / profiling?

adamhaney avatar Jul 12 '13 19:07 adamhaney

http://fixunix.com/unix/353470-intercepting-system-calls-linux.html

http://my.safaribooksonline.com/0131774298/ch05lev1sec4?portal=adobepress

adamhaney avatar Jul 12 '13 20:07 adamhaney