APPROVE COMMIT
NOTE: This patch has been committed
# HG changeset patch
# User Aidan Kehoe <kehoea(a)parhasard.net>
# Date 1534245455 -3600
# Tue Aug 14 12:17:35 2018 +0100
# Node ID 99135ed6ffc1217d9082691df80fb3a3471785ce
# Parent ebbb3bbb899aae849c9c66f4bc16825240be3637
Make #'make-weak-box work when running compiled, too.
lisp/ChangeLog addition:
2018-08-14 Aidan Kehoe <kehoea(a)parhasard.net>
* misc.el (make-weak-box):
Make this code work when run compiled too, not that it will come
up much.
diff -r ebbb3bbb899a -r 99135ed6ffc1 lisp/ChangeLog
--- a/lisp/ChangeLog Mon Aug 13 13:06:14 2018 +0100
+++ b/lisp/ChangeLog Tue Aug 14 12:17:35 2018 +0100
@@ -1,3 +1,9 @@
+2018-08-14 Aidan Kehoe <kehoea(a)parhasard.net>
+
+ * misc.el (make-weak-box):
+ Make this code work when run compiled too, not that it will come
+ up much.
+
2018-08-13 Aidan Kehoe <kehoea(a)parhasard.net>
* misc.el (make-weak-box):
diff -r ebbb3bbb899a -r 99135ed6ffc1 lisp/misc.el
--- a/lisp/misc.el Mon Aug 13 13:06:14 2018 +0100
+++ b/lisp/misc.el Tue Aug 14 12:17:35 2018 +0100
@@ -96,7 +96,10 @@
#'(lambda (weak-box)
(cdr (assq weak-box
(weak-list-list all-weak-boxes)))))
- (setq all-weak-boxes (make-weak-list 'assoc))))
+ ;; Use defvar so calls to #'make-weak-box when it is
+ ;; interpreted don't reset all-weak-boxes every time.
+ (defvar all-weak-boxes (make-weak-list 'assoc))
+ all-weak-boxes))
(acons (vector 'cl-weak-box nil)
contents (weak-list-list all-weak-boxes))))))
;; The second element of the vector is the eq hash of the vector itself,
--
‘As I sat looking up at the Guinness ad, I could never figure out /
How your man stayed up on the surfboard after forty pints of stout’
(C. Moore)