clojure-site icon indicating copy to clipboard operation
clojure-site copied to clipboard

`evaluation.adoc` is inconsistent with current function evaluation semantics

Open w01fe opened this issue 9 years ago • 0 comments

evaluation.adoc states that "Any object other than those discussed above will evaluate to itself," without mentioning function objects. In CLJ-1206, it was reported that certain function objects cause errors in eval, when nested in a form (and since that bug was opened, several others have independently run into this problem and posted on the mailing list).

A fix for CLJ-1206 was declined, with the prevailing opinion seeming to be that eval should not be applied to non-data-structure'y things. If that's the case, clojure.org/reference/evaluation should probably be updated to correctly describe the semantics of eval, and which "other objects" are guaranteed to evaluate to themselves, versus error, versus trigger undefined behavior.

w01fe avatar May 15 '16 08:05 w01fe