GNU bug report logs - #17355
#:getter procedure returns unexpected value in GOOPS

Previous Next

Package: guile;

Reported by: "Diogo F. S. Ramos" <dfsr <at> riseup.net>

Date: Sun, 27 Apr 2014 04:54:01 UTC

Severity: important

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 17355 in the body.
You can then email your comments to 17355 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#17355; Package guile. (Sun, 27 Apr 2014 04:54:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to "Diogo F. S. Ramos" <dfsr <at> riseup.net>:
New bug report received and forwarded. Copy sent to bug-guile <at> gnu.org. (Sun, 27 Apr 2014 04:54:02 GMT) Full text and rfc822 format available.

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

From: "Diogo F. S. Ramos" <dfsr <at> riseup.net>
To: bug-guile <at> gnu.org
Subject: #:getter procedure returns unexpected value in GOOPS
Date: Sat, 26 Apr 2014 22:43:41 -0300
When using GOOPS, if a class has a second slot, the #:getter procedure
of the first slot returns the value of the second slot when applied to
an instance of a subclass.

--8<---------------cut here---------------start------------->8---
(use-modules (oop goops))

(define-class <foo> ()
  (a #:init-form 'foo #:getter foo-a)
  (b #:init-form 42))

(define-class <bar> (<foo>)
  (a #:init-form 'bar))
--8<---------------cut here---------------end--------------->8---

  (foo-a (make <foo>)) => foo
  (foo-a (make <bar>)) => 42

I expected:

  (foo-a (make <bar>)) => bar

I'm using Guile 2.0.11.




Severity set to 'important' from 'normal' Request was from Mark H Weaver <mhw <at> netris.org> to control <at> debbugs.gnu.org. (Wed, 10 Dec 2014 17:11:04 GMT) Full text and rfc822 format available.

Reply sent to Andy Wingo <wingo <at> pobox.com>:
You have taken responsibility. (Tue, 21 Jun 2016 13:13:02 GMT) Full text and rfc822 format available.

Notification sent to "Diogo F. S. Ramos" <dfsr <at> riseup.net>:
bug acknowledged by developer. (Tue, 21 Jun 2016 13:13:02 GMT) Full text and rfc822 format available.

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

From: Andy Wingo <wingo <at> pobox.com>
To: "Diogo F. S. Ramos" <dfsr <at> riseup.net>
Cc: 17355-done <at> debbugs.gnu.org
Subject: Re: bug#17355: #:getter procedure returns unexpected value in GOOPS
Date: Tue, 21 Jun 2016 15:12:22 +0200
Thanks for the report!  This is fixed in Guile 2.0.11 and in 2.1.x,
though the full situation is a bit strange.

See: http://thread.gmane.org/gmane.lisp.guile.user/11218/focus=11813

Regards,

Andy

On Sun 27 Apr 2014 03:43, "Diogo F. S. Ramos" <dfsr <at> riseup.net> writes:

> When using GOOPS, if a class has a second slot, the #:getter procedure
> of the first slot returns the value of the second slot when applied to
> an instance of a subclass.
>
> (use-modules (oop goops))
>
> (define-class <foo> ()
>   (a #:init-form 'foo #:getter foo-a)
>   (b #:init-form 42))
>
> (define-class <bar> (<foo>)
>   (a #:init-form 'bar))
>
>   (foo-a (make <foo>)) => foo
>   (foo-a (make <bar>)) => 42
>
> I expected:
>
>   (foo-a (make <bar>)) => bar
>
> I'm using Guile 2.0.11.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 20 Jul 2016 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 8 years and 340 days ago.

Previous Next


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