From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Robin Templeton Newsgroups: gmane.lisp.guile.bugs Subject: bug#24321: Guardian fails to protect procedure properties Date: Sat, 27 Aug 2016 15:32:20 -0400 Message-ID: <87shtqt3cr.fsf@panthera.terpri.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1472326398 29867 195.159.176.226 (27 Aug 2016 19:33:18 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 27 Aug 2016 19:33:18 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) To: 24321@debbugs.gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Sat Aug 27 21:33:14 2016 Return-path: Envelope-to: guile-bugs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bdjLu-0007Lh-76 for guile-bugs@m.gmane.org; Sat, 27 Aug 2016 21:33:14 +0200 Original-Received: from localhost ([::1]:37014 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bdjLr-0006NG-K1 for guile-bugs@m.gmane.org; Sat, 27 Aug 2016 15:33:11 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54206) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bdjLm-0006N9-Ib for bug-guile@gnu.org; Sat, 27 Aug 2016 15:33:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bdjLi-0004ML-Ek for bug-guile@gnu.org; Sat, 27 Aug 2016 15:33:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:44509) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bdjLi-0004MH-BV for bug-guile@gnu.org; Sat, 27 Aug 2016 15:33:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1bdjLi-0008NI-7M for bug-guile@gnu.org; Sat, 27 Aug 2016 15:33:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Robin Templeton Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Sat, 27 Aug 2016 19:33:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 24321 X-GNU-PR-Package: guile X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-guile@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.147232636832171 (code B ref -1); Sat, 27 Aug 2016 19:33:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 27 Aug 2016 19:32:48 +0000 Original-Received: from localhost ([127.0.0.1]:42221 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bdjLU-0008Mp-L0 for submit@debbugs.gnu.org; Sat, 27 Aug 2016 15:32:48 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:34969) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bdjLS-0008Mc-JP for submit@debbugs.gnu.org; Sat, 27 Aug 2016 15:32:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bdjLM-0004JS-Jg for submit@debbugs.gnu.org; Sat, 27 Aug 2016 15:32:41 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:59372) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bdjLM-0004IS-HD for submit@debbugs.gnu.org; Sat, 27 Aug 2016 15:32:40 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54173) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bdjLK-00064r-BT for bug-guile@gnu.org; Sat, 27 Aug 2016 15:32:39 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bdjLG-0004Hr-73 for bug-guile@gnu.org; Sat, 27 Aug 2016 15:32:37 -0400 Original-Received: from [195.159.176.226] (port=47092 helo=blaine.gmane.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bdjLG-0004Ge-0i for bug-guile@gnu.org; Sat, 27 Aug 2016 15:32:34 -0400 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1bdjL9-000378-Vh for bug-guile@gnu.org; Sat, 27 Aug 2016 21:32:27 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 24 Original-X-Complaints-To: usenet@blaine.gmane.org Cancel-Lock: sha1:3pupTgNUfyrPnDWyn5YGh7u1PRE= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Original-Sender: "bug-guile" Xref: news.gmane.org gmane.lisp.guile.bugs:8388 Archived-At: The following expression produces possibly erroneous results in Guile 2.1.3.104-8f2f8 (with Debian's libgc1c2 version 1:7.4.2-8): (let ((guardian (make-guardian)) (foo (eval '(lambda () #f) (interaction-environment)))) (set-procedure-property! foo 'wibbly 'wobbly) (guardian foo) (format #t "~S~%" (procedure-properties foo)) (set! foo #f) (gc) (do ((foo (guardian) (guardian))) ((not foo)) (format #t "~S~%" (procedure-properties foo)))) First it prints "((wibbly . wobbly))" as expected, but after the procedure is retrieved from the guardian the list of properties is empty. The properties are stored in a weak hash table, but shouldn't they be protected from GC while the procedure is in the guardian? -- Inteligenta persono lernas la lingvon Esperanton rapide kaj facile. Esperanto estas moderna, kultura lingvo por la mondo. Simpla, fleksebla, belsona, Esperanto estas la praktika solvo de la problemo de universala interkompreno. Lernu la interlingvon Esperanton!