search for: my_new_env

Displaying 1 result from an estimated 1 matches for "my_new_env".

2015 Dec 10
6
How do I reliably and efficiently hash a function?
...change. On the chance that I?m trying to solve the wrong Y to an X/Y problem, the full context to the above problem is explained in [1]. In a nutshell, I am hooking a new environment into a function?s parent.env chain, by re-assigning the function?s `parent.env` (naughty, I know): ``` parent.env(my_new_env) = parent.env(f) parent.env(f) = my_new_env ``` This is done so that the function `f` finds objects defined inside that environment without having to attach it globally. However, for bookkeeping purposes I need to preserve the original parent environment ? hence the question. [1]: https://github....