GNU bug report logs - #38611
Guile 2.9.7 regression: "duplicate" record field names

Previous Next

Package: guile;

Reported by: Göran Weinholt <goran <at> weinholt.se>

Date: Sat, 14 Dec 2019 20:53:02 UTC

Severity: normal

Done: Andy Wingo <wingo <at> pobox.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 38611 in the body.
You can then email your comments to 38611 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guile <at> gnu.org:
bug#38611; Package guile. (Sat, 14 Dec 2019 20:53:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Göran Weinholt <goran <at> weinholt.se>:
New bug report received and forwarded. Copy sent to bug-guile <at> gnu.org. (Sat, 14 Dec 2019 20:53:02 GMT) Full text and rfc822 format available.

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

From: Göran Weinholt <goran <at> weinholt.se>
To: bug-guile <at> gnu.org
Subject: Guile 2.9.7 regression: "duplicate" record field names
Date: Sat, 14 Dec 2019 14:31:10 +0100
Hello schemers,

The following program works in Guile 2.2.6 (and other R6RS
implementations), but raises an exception in Guile 2.9.7. A field called
"name" exists in record type a and record type b, but there is no actual
naming conflict as I understand it.

--8<---------------cut here---------------start------------->8---
(import (rnrs))

(define-record-type a
  (fields name))

(define-record-type b
  (parent a)
  (fields name))

(let ((x (make-b 'a 'b)))
  (write (list (a-name x)
               (b-name x)))
  (newline))
--8<---------------cut here---------------end--------------->8---

It should print (a b). The backtrace:

--8<---------------cut here---------------start------------->8---
Backtrace:
In ice-9/boot-9.scm:
  1722:10  8 (with-exception-handler _ _ #:unwind? _ # _)
In unknown file:
           7 (apply-smob/0 #<thunk 56291f86b320>)
In ice-9/boot-9.scm:
    718:2  6 (call-with-prompt _ _ #<procedure default-prompt-handle?>)
In ice-9/eval.scm:
    619:8  5 (_ #(#(#<directory (guile-user) 56291f8eff00>)))
In ice-9/boot-9.scm:
   2792:4  4 (save-module-excursion _)
  4336:12  3 (_)
In /tmp/foo.sps:
      6:0  2 (_)
In ice-9/boot-9.scm:
  1090:10  1 (make-record-type b ((immutable name)) _ #:parent _ # _ ?)
  1073:12  0 (append-fields _ _)

ice-9/boot-9.scm:1073:12: In procedure append-fields:
duplicate field name
--8<---------------cut here---------------end--------------->8---

Regards,

-- 
Göran Weinholt   | https://weinholt.se/
Debian developer | 73 de SA6CJK




Reply sent to Andy Wingo <wingo <at> pobox.com>:
You have taken responsibility. (Sun, 12 Jan 2020 20:58:02 GMT) Full text and rfc822 format available.

Notification sent to Göran Weinholt <goran <at> weinholt.se>:
bug acknowledged by developer. (Sun, 12 Jan 2020 20:58:02 GMT) Full text and rfc822 format available.

Message #10 received at 38611-done <at> debbugs.gnu.org (full text, mbox):

From: Andy Wingo <wingo <at> pobox.com>
To: Göran Weinholt <goran <at> weinholt.se>
Cc: 38611-done <at> debbugs.gnu.org
Subject: Re: bug#38611: Guile 2.9.7 regression: "duplicate" record field names
Date: Sun, 12 Jan 2020 21:56:55 +0100
On Sat 14 Dec 2019 14:31, Göran Weinholt <goran <at> weinholt.se> writes:

> The following program works in Guile 2.2.6 (and other R6RS
> implementations), but raises an exception in Guile 2.9.7. A field called
> "name" exists in record type a and record type b, but there is no actual
> naming conflict as I understand it.
>
> (import (rnrs))
>
> (define-record-type a
>   (fields name))
>
> (define-record-type b
>   (parent a)
>   (fields name))
>
> (let ((x (make-b 'a 'b)))
>   (write (list (a-name x)
>                (b-name x)))
>   (newline))

Fixed in master.  Thanks for the report!

Andy




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 10 Feb 2020 12:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 48 days ago.

Previous Next


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