[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
General 8 allocate-funcallable-instance-1
- To: CommonLoops.pa@Xerox.COM
- Subject: General 8 allocate-funcallable-instance-1
- From: Charles Hornig <Hornig@PROTO-RIVERSIDE.SCRC.Symbolics.COM>
- Date: Fri, 25 May 90 06:35 EDT
- Comments: Retransmission of failed mail. Retransmission of failed mail.
- In-reply-to: <900523-170735-1761@Xerox>
- Redistributed: CommonLoops.pa
- Supersedes: <19900525185229.4.HORNIG@CRAWLER.SCRC.Symbolics.COM>, <19900525204049.2.HORNIG@CRAWLER.SCRC.Symbolics.COM>
Date: Tue, 22 May 90 23:05:31 -0400
From: kanderso@DINO.BBN.COM
The following #+Genera function (from fin.lisp) does not work in
general 8.0 because they added fin as a type of lexical closure.
This change doesn't work. It smashes the CDR-code of the lexical
closure to be CDR-NORMAL, which disconnects the first 2 words from the
rest of the FIN. At some point the GC will separate them, resulting in
disaster. Making PCL work in 8.0 is not this easy.
I have a version of May Day PCL that runs in 8.0. I'm willing to send
it to anyone who can maintain a publicly-accessible copy.
(defun allocate-funcallable-instance-1 ()
(let* ((whole-fin (make-list (+ 3 (length funcallable-instance-data))))
(new-fin (sys:%make-pointer-offset sys:dtp-lexical-closure
whole-fin
0)))
;;
;; note that we DO NOT turn the real lex-closure part of the fin into
;; a dotted pair, because (1) the machine doesn't care and (2) if we
;; did the garbage collector would reclaim everything after the lexical
;; function.
;;
(setf (sys:%p-contents-offset new-fin 2) *funcallable-instance-marker*)
(setf (si:lexical-closure-function new-fin)
#'(lambda (ignore &rest ignore-them-too)
(declare (ignore ignore ignore-them-too))
(called-fin-without-function)))
#+GENERA-RELEASE-8
(SETF (SI:LEXICAL-CLOSURE-SUBTYPE NEW-FIN) SI:LEXICAL-CLOSURE-SUBTYPE-LEXICAL-CLOSURE)
#+ignore
(setf (si:lexical-closure-environment new-fin) nil)
new-fin))