gcl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gcl-devel] Re: side-effects -- say what?


From: Camm Maguire
Subject: [Gcl-devel] Re: side-effects -- say what?
Date: 28 Feb 2006 09:33:08 -0500
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

Greetings!

Robert Boyer <address@hidden> writes:

> > To my understanding, for the purposes of the GCL compiler, a good
> > definition of side-effect would be "to write to non-freshly allocated
> > heap memory other than dynamic symbol value bindings".
> 
> So by this definition is CONS or + side-effect free by this definition?
> 
> I don't think so, since both can invoke the garbage collector.  Is EQ
> side-effect free?  It might cause a stack overflow which could invoke the
> error handler, etc.
> 
> So I think one has to be more careful in the definition.
> 
> Picky, picky.
> 

Not picky at all, but rather comprehensive.  I think the term
side-effect is bad for the purpose at hand, which is why I tried to
qualify the above with "for the purposes of the GCL compiler ...".
All we want to know here is that the type of a given object is
consistent across form evaluation.  The gc needs to ensure that this
is the case for all live pointers in force at the time of invocation
-- likewise the error handler.  So in this context I would say that
cons and + are side effect free, as they do not spoil the type
information gathered above the form when it might want to be used
below the form.

Take care, 

> Bob
> 
> 
> 
> 
> 
> 

-- 
Camm Maguire                                            address@hidden
==========================================================================
"The earth is but one country, and mankind its citizens."  --  Baha'u'llah




reply via email to

[Prev in Thread] Current Thread [Next in Thread]