Replying to myself...
> David Kastrup writes:
>> I am not sure about the strength of the respective dependencies, but let
>> me just say that "universally-unique gensyms" as an idea has a bad ring
>> to me. It makes the output of the compiler non-deterministic. This
>> makes a lot of simple ver
David Kastrup writes:
> I am not sure about the strength of the respective dependencies, but let
> me just say that "universally-unique gensyms" as an idea has a bad ring
> to me. It makes the output of the compiler non-deterministic. This
> makes a lot of simple verification methods (like check
Mark H Weaver writes:
> Call me stubborn, but I _still_ think it would be better to use this
> implementation in 2.0.4, and to revert both `syntax-local-binding' and
> maybe also `universally-unique gensyms' for now. I'm not opposed to
> Andy's approach, but I think we need more time to debate t
. This way, we have complete freedom to do whatever we want
in 2.0.5 and beyond, without making any hasty commitments.
Best,
Mark
>From 496c5ae9f8d8b835dcb9a032447df2f46e2d63bd Mon Sep 17 00:00:00 2001
From: Mark H Weaver
Date: Tue, 3 Jan 2012 04:02:08 -0500
Subject: [PATCH] Implement `
Hi Mark,
On Sun 08 Jan 2012 21:39, Mark H Weaver writes:
Are there some short primitives that psyntax could export that
would make it possible to implement `the-environment' in a module?
>
>>> * The list of ordinary variables (these need to be boxed)
>>> * The list of simulated variabl
Hi Mark,
On Sun 08 Jan 2012 21:39, Mark H Weaver writes:
> Andy Wingo writes:
>> I guess it's not clear to me why you would want to force expression
>> context.
>
> If we allow definitions, then your nice equivalence
>
>== (local-eval ' (the-environment))
>
> no longer holds. Also, the use
Hi Mark,
On Sun 08 Jan 2012 21:39, Mark H Weaver writes:
> Andy Wingo writes:
>>> We could change that, but I'm reluctant to make the evaluator any
>>> slower than it already is.
>>
>> Using variable objects has the possibility to make the evaluator faster,
>> actually, if at the same time we m
environment (formerly called
box-lambda*).
I have attached a revised patch with the following changes:
* tabs => spaces
* Completely reworked the implementation of `the-environment' in
psyntax, to hopefully be easier to read and understand, at the cost of
some efficiency.
* The lexical en
Hi Mark,
On Sat 07 Jan 2012 21:20, Mark H Weaver writes:
> The problem is that primitive-eval does not represent lexical variables
> as variable objects.
True.
> We could change that, but I'm reluctant to make the evaluator any
> slower than it already is.
Using variable objects has the possi
Hi Andy, thanks for the code review! :)
Andy Wingo writes:
> On Tue 03 Jan 2012 11:52, Mark H Weaver writes:
>
>> +(define-record-type lexical-environment-type
>> + (make-lexical-environment wrapper names boxes others module-name)
>> + lexical-environment?
>> + (wrapper lexenv-wrapper)
>>
On Wed 04 Jan 2012 01:06, Mark H Weaver writes:
> Here's an improved version of the patch. Most notably, I removed the
> `#:to' parameter to `local-compile', since I realized it couldn't be
> implemented properly anyway. I also updated the copyright notices to
> 2012 in all changed files, and m
On Tue 03 Jan 2012 11:52, Mark H Weaver writes:
> +(define-record-type lexical-environment-type
> + (make-lexical-environment wrapper names boxes others module-name)
> + lexical-environment?
> + (wrapper lexenv-wrapper)
> + (names lexenv-names)
> + (boxes lexenv-boxes)
> + (
David Kastrup writes:
> Ah, I see that set! has made it explicitly into the patterns. What
> about
>
> (define foo (make-procedure-with-setter vector-ref vector-set!))
>
> (let ((env
> (let ((x (make-vector 2 #f)))
>(the-environment
>(local-eval '(set! (foo x 1) 3) env))
Alth
David Kastrup writes:
> Ah, I see that set! has made it explicitly into the patterns. What
> about
>
> (define foo (make-procedure-with-setter vector-ref vector-set!))
>
> (let ((env
> (let ((x (make-vector 2 #f)))
>(the-environment
>(local-eval '(set! (foo x 1) 3) env))
Both
Mark H Weaver writes:
> David Kastrup writes:
>
>> How will either fare with:
>>
>> (let ((env
>> (let ((x 1))
>> (the-environment
>> (local-eval '(set! x 4) env))
>
> This example (or more complex ones based on the same idea) present no
> difficulties for either patch.
Ah, I see th
cleanups.
Best,
Mark
>From a8b587cd9c25d4e1a999e870190edf472561f8f2 Mon Sep 17 00:00:00 2001
From: Mark H Weaver
Date: Tue, 3 Jan 2012 04:02:08 -0500
Subject: [PATCH] Implement `local-eval', `local-compile', and
`the-environment'
* module/ice-9/local-eval.scm: New mod
David Kastrup writes:
> How will either fare with:
>
> (let ((env
> (let ((x 1))
> (the-environment
> (local-eval '(set! x 4) env))
This example (or more complex ones based on the same idea) present no
difficulties for either patch.
scheme@(guile-user)> (use-modules (ice-9 local-e
Mark H Weaver writes:
> Hello all,
>
> I have now produced two very different implementations of
> `the-environment' and `local-eval' that support compilation.
>
> Included below is a simple patch that I believe is ready for commit to
> the stable-2.0 branch, and I very much hope it can be includ
t compiles the
local expression instead of using `eval'.
Anyway, here's the patch. As before, I cut out the psyntax-pp.scm
patch, since it's so huge. Regenerate it with:
make -C module ice-9/psyntax-pp.scm.gen
Comments and suggestions solicited.
Best,
Mark
>From 801
19 matches
Mail list logo