;; The hard case, answered without looking at a single call site: a function ;; value that arrives as a parameter may carry an environment on its caller's ;; frame, so a function that *stores* one is refused where it is written. ;; ;; That is what makes passing a capturing fn down safe everywhere — no callee ;; can keep it — and it is also the conservative half: this particular [keep] ;; would be harmless for a caller that passed a name, and there is no way for ;; the definition to know that it did. (defn keep [f (Fn [] i32)] (Fn [] i32) f) (defn main [] i32 (println ((keep (fn [] 1)))) 0)