Path: utzoo!attcan!utgpu!news-server.csri.toronto.edu!rutgers!cs.utexas.edu!rice!news From: wright@utopia.rice.edu (Andrew Wright) Newsgroups: comp.lang.lisp Subject: Re: Weak Reference in Common Lisp Message-ID: <1990Aug18.190312.25603@rice.edu> Date: 18 Aug 90 19:03:12 GMT References: <81084@aerospace.AERO.ORG> <5819@hplabsz.HPL.HP.COM> <44659@cornell.UUCP> Sender: news@rice.edu (News) Distribution: usa Organization: Rice University, Houston Lines: 24 In article <44659@cornell.UUCP> murthy@algron.cs.cornell.edu (Chet Murthy) writes: >>In article <81084@aerospace.AERO.ORG> srt@aero.org (Scott "TCB" Turner) writes: >>>Is there a mechanism in Common Lisp (specifically AKCL) for weak >>>reference? By weak reference I mean a reference that won't prevent >>>garbage collection if no other references exist. >I know that there is such a facility (weak pointers) in the SML-NJ >(Standard ML of New Jersey) system. I think Chet must be referring to "weak types" of standard ML. SML's weak types have nothing to do with what the original poster intended. SML may be thot of, loosely, as lisp with a static polymorphic type system. Reference cells are given a "weak" or "imperative" type in order that they interact properly with polymorphism. The semantics of imperative types are presented in "The Definition of Standard ML", by Milner, Tofte and Harper, MIT Press 1990, and are explained in more detail in Tofte's Phd thesis (Edinburgh). The term "weak" refers to an extension of "imperative" as implemented by Appel and MacQueen in Standard ML of New Jersey, and described only very briefly in the release documentation. Andrew K. Wright Computer Science, Rice University wright@rice.edu Houston Texas 77251-1892