GNU bug report logs - #33827
SRFI 69 weak hash-tables is broken

Previous Next

Package: guile;

Reported by: Jéssica Milaré <jessymilare <at> gmail.com>

Date: Fri, 21 Dec 2018 16:23:01 UTC

Severity: normal

Full log


Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Jéssica Milaré <jessymilare <at> gmail.com>
To: bug-guile <at> gnu.org
Subject: SRFI 69 weak hash-tables is broken
Date: Fri, 21 Dec 2018 09:13:50 -0200
[Message part 1 (text/plain, inline)]
The srfi-69 implementation that comes with Guile doesn't function properly
when some non-false #:weak argument is provided. The problems seems to be
that it tries to use handles, which are only available for non-weak
hash-tables.

scheme@(guile-user)> (import (srfi :69))
scheme@(guile-user)> (define ht (make-hash-table eq? hashq #:weak 'key))
scheme@(guile-user)> (hash-table-set! ht 10 10)
ERROR: In procedure hashx-create-handle!:
In procedure scm_hash_fn_create_handle_x: Wrong type argument in position 1
(expecting hash-table): #<weak-table 0/31>

Entering a new prompt.  Type `,bt' for a backtrace or `,q' to continue.
scheme@(guile-user) [1]>


Regards,
Jessica
[Message part 2 (text/html, inline)]

This bug report was last modified 6 years and 153 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.