Questions tagged [pure-functions]
For questions about functions that give identical outputs for identical inputs between separate calls and do not have any program-visible side effects.
3 questions
9
votes
2
answers
487
views
Can total (primitive) corecursion be implemented?
I'm trying to understand how to implement corecursion in a total functional context. I've already implemented recursion using standard techniques (for loops) but I ...
3
votes
3
answers
254
views
What are the downsides, if any, of using implicit function purity in an impure language?
An idea I had for one of my languages recently was this: function purity makes it easier to do certain optimizations. However, the language I'm designing is an impure imperative language that has an ...
7
votes
3
answers
824
views
How to verify function purity in an imperative language?
A pure function in an imperative language means one with no observable side-effects, which when called multiple times with identical arguments will always return identical results, and which doesn't ...