On 05/15/2014 08:03 PM, Andrei Alexandrescu wrote:
Purity of allocation is frequently assumed by functional languages
Examples?
cons 1 2 is equal to cons 1 2
...
I don't see anything whose specification would need to mention 'allocation'.
because without it it would be difficult to get much work done.
Why?
It's rather obvious. You've got to have the ability to create new values
in a pure functional programming language.
This kind of operational reasoning is not essential. Of course, in
practice you want to evaluate expressions, but the resulting programs
are of the same kind as those of a non-pure language, and can do the
same kind of operations. There is not really a distinction to be made at
that level of abstraction.