Evals a form with given locals. The locals should be a map of symbols to
values.
(defn with-env-locals
"Evals a form with given locals. The locals should be a map of symbols to
values."
[form]
(let [m (local-non-functions *current-env*)]
(if (first m)
`(let ~(vec (mapcat #(list % (m %)) (keys m)))
~form)
form)))
Comments top
No comments for with-env-locals. Log in to add a comment.