tag:blogger.com,1999:blog-8288194986820249216.post4132627262157554480..comments2024-03-22T05:09:17.789-07:00Comments on Abstract Heresies: First-class environmentsJoe Marshallhttp://www.blogger.com/profile/03233353484280456977noreply@blogger.comBlogger3125tag:blogger.com,1999:blog-8288194986820249216.post-20648102723533189252020-02-19T07:44:16.375-08:002020-02-19T07:44:16.375-08:00Ten years down the road, I note that Scheme alread...Ten years down the road, I note that Scheme already has <i>global</i> environments (the second argument to eval) which are unfortunately not quite first-class. In R6RS you can create a new global environment and import libraries into it, but the result is immutable; indeed, the only environment guaranteed immutable is plain old (interaction-environment). I have a <a href="https://bitbucket.org/cowan/r7rs-wg1-infra/src/default/EnvironmentsMIT.md" rel="nofollow">pre-SRFI</a> that adapts MIT's environment tree to the R6RS world, but works on global environments only.John Cowanhttps://www.blogger.com/profile/11452247999156925669noreply@blogger.comtag:blogger.com,1999:blog-8288194986820249216.post-46404887288345143632009-09-25T01:52:00.415-07:002009-09-25T01:52:00.415-07:00What do I need if I want to write a pretty printer...What do I need if I want to write a pretty printer for functions? I think I need choices [1,2,2,2], which seems not terribly harmful. <br /><br />Those choices would let me, for example, serialize functions (along with their bindings) in a way I can later eval them back in, and though they won't be eq to the original ones, have at least a shot at wondering whether they might be, in another weak sense, equal (not, of course, in the more general, non-computable sense). It can also just be useful for debugging of normal code. <br /><br />Guile provides facilities for this, at least up until the top level environment, which is harder to inspect, but that's actually okay: I don't want to serialize out the meaning of + in most cases.<br /><br />Is that a target for standardization?Gregory Martonhttps://www.blogger.com/profile/07972033061062689944noreply@blogger.comtag:blogger.com,1999:blog-8288194986820249216.post-53643495490301987112009-09-25T01:49:02.596-07:002009-09-25T01:49:02.596-07:00I always find the argument that some language cons...I always find the argument that some language construct is supposedly "dangerous" a bit weird. It's too fuzzy to make such a statement, in my humble opinion. What's more important, I think, is this: Do you want to be able to implement portable runtime debuggers or not? If you want this, you need first-class environments.Pascal Costanzahttps://www.blogger.com/profile/04512975624438301971noreply@blogger.com