From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Pirotte Newsgroups: gmane.lisp.guile.user Subject: Re: #:getter procedure returns unexpected value in GOOPS Date: Fri, 2 May 2014 01:36:07 -0300 Message-ID: <20140502013607.65532c78@capac> References: <87mwf9hu1v.fsf@nebulosa.milkyway> <87ppk38tek.fsf@yeeloong.lan> <20140427191451.674c60b2@capac> <8761lu8dg3.fsf@yeeloong.lan> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1399005408 24411 80.91.229.3 (2 May 2014 04:36:48 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 2 May 2014 04:36:48 +0000 (UTC) Cc: guile-user@gnu.org To: Mark H Weaver Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Fri May 02 06:36:42 2014 Return-path: Envelope-to: guile-user@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Wg5DG-0005FV-CZ for guile-user@m.gmane.org; Fri, 02 May 2014 06:36:42 +0200 Original-Received: from localhost ([::1]:42222 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wg5DF-0004jZ-Rg for guile-user@m.gmane.org; Fri, 02 May 2014 00:36:41 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:55289) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wg5D1-0004jK-6x for guile-user@gnu.org; Fri, 02 May 2014 00:36:33 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Wg5Cv-0000xi-0M for guile-user@gnu.org; Fri, 02 May 2014 00:36:27 -0400 Original-Received: from maximusconfessor.all2all.org ([79.99.200.102]:57044) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wg5Cu-0000xd-Pk for guile-user@gnu.org; Fri, 02 May 2014 00:36:20 -0400 Original-Received: from localhost (unknown [192.168.0.2]) by maximusconfessor.all2all.org (Postfix) with ESMTP id 37877A04C121; Fri, 2 May 2014 06:36:19 +0200 (CEST) Original-Received: from maximusconfessor.all2all.org ([192.168.0.1]) by localhost (maximusconfessor.all2all.org [192.168.0.2]) (amavisd-new, port 10024) with ESMTP id nccDZ+TUBdIr; Fri, 2 May 2014 06:17:55 +0200 (CEST) Original-Received: from capac (unknown [189.60.2.251]) by maximusconfessor.all2all.org (Postfix) with ESMTPSA id 94FDFA04C0F5; Fri, 2 May 2014 06:36:11 +0200 (CEST) In-Reply-To: <8761lu8dg3.fsf@yeeloong.lan> X-Mailer: Claws Mail 3.9.3 (GTK+ 2.24.23; x86_64-pc-linux-gnu) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 79.99.200.102 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Original-Sender: guile-user-bounces+guile-user=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.user:11248 Archived-At: Hi Mark, > Read this: > > http://clhs.lisp.se/Body/07_ec.htm Perfect, thanks for the link and the confirmation. Note that in the current implementation, guile's problem is not the [proper] initialization of the inherited slot, as I did show and as you can check, slot-ref works as expected on Diego's example. One can also use describe for that matter (oop goops describe) .. The problem is that getters, setters and accessors although [merely] inherited are not properly recomputed. Your temporary solution is nice, but only works if there is no need for a change of the inherited slot allocation option, and would not solve the 'quantum mechanic' slot states :) that my 'consider the following situation' example shows. Therefore, in the mean time, I personally would recommend goops users to redefine getters, setters and accessors they are using/plan to use on their subclasse's instances, since it is currently the only way to 'force' guile to do his job properly. > Here's a transcript of an SBCL session I tried on Debian: Yep, I've downloaded it too now, it's been a while I did not play with lisp :) I much prefer scheme and guile now. But then I am not surprised they got it right, for lispers clos is an old beast and lisp implementations have, by far, much much more code and many many more testers as well, indeed clos is so much more used by lispers then goops by schemers. Cheers, David