From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andy Wingo Newsgroups: gmane.lisp.guile.bugs Subject: Re: module system / (oop goops) / :duplicates (merge-generics) / bug? Date: Thu, 18 Aug 2011 13:01:34 +0200 Message-ID: <87bovngf01.fsf@pobox.com> References: <20110705183229.6f779a6b@rascar> <87vcvfcrjc.fsf@gnu.org> <20110706162244.2bf4b90a@rascar> <87ipre48zj.fsf@pobox.com> <20110707132659.2cee382d@rascar> <87box54xjg.fsf@pobox.com> <20110708140559.6ed55cd9@rascar> <87tyav3h7q.fsf@pobox.com> <20110709120816.0827236b@rascar> <87aack3jif.fsf@pobox.com> <20110711222555.4bd45679@rascar> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1313669239 4432 80.91.229.12 (18 Aug 2011 12:07:19 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 18 Aug 2011 12:07:19 +0000 (UTC) Cc: bug-guile@gnu.org, Ludovic =?utf-8?Q?Court=C3=A8s?= To: David Pirotte Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Thu Aug 18 14:07:15 2011 Return-path: Envelope-to: guile-bugs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Qu1NP-0007sD-Eh for guile-bugs@m.gmane.org; Thu, 18 Aug 2011 14:07:11 +0200 Original-Received: from localhost ([::1]:40720 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qu1NO-0004D2-NO for guile-bugs@m.gmane.org; Thu, 18 Aug 2011 08:07:10 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:56333) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qu1NL-00048y-0W for bug-guile@gnu.org; Thu, 18 Aug 2011 08:07:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qu1NJ-0000RR-SB for bug-guile@gnu.org; Thu, 18 Aug 2011 08:07:06 -0400 Original-Received: from a-pb-sasl-sd.pobox.com ([74.115.168.62]:40856 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qu1NJ-0000RI-Ps; Thu, 18 Aug 2011 08:07:05 -0400 Original-Received: from sasl.smtp.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id A232063F5; Thu, 18 Aug 2011 08:07:05 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=sasl; bh=VuDpz3G+sKgeVKhvwq5NalSpFAY=; b=HVfsCr qjhAuAr5jC8a5fkaYhXeXLyFrfjUNmZb3BHbbI/xrA6kVqRsCToFijGSSHd0vNHE ppBSjMzH1RFQBzrMO68MMMjQvx1vh+TQ6fqw3k69WJZ0hHH5McuyJm/IB52tBXKn 6Snl71BpmRAxWBwRUh7PGexjuadGUWkwJdobc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; q=dns; s=sasl; b=qcvY8xdKWmrL9GI5hq2TdZCOmsUQxBAk UgIgH+Vipq/zE3Ai9u6w78ue1uaq2p+ZXtsPh9X3ou4Q1D41YarwIoiUA3p1ydhp 1S8Y1ZXzV7a8NPf+qtD2aNQ1MSa/IGYVfpSPZIDmZy19/LwGtHz4sDEqFv0fxvaw yGz3fLHahPY= Original-Received: from a-pb-sasl-sd.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 7E68F63F4; Thu, 18 Aug 2011 08:07:05 -0400 (EDT) Original-Received: from badger (unknown [90.164.198.39]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTPSA id AAB4663F3; Thu, 18 Aug 2011 08:07:04 -0400 (EDT) In-Reply-To: <20110711222555.4bd45679@rascar> (David Pirotte's message of "Mon, 11 Jul 2011 22:25:55 -0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) X-Pobox-Relay-ID: 967F48CC-C992-11E0-9E8A-B797DE995924-02397024!a-pb-sasl-sd.pobox.com X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) X-Received-From: 74.115.168.62 X-BeenThere: bug-guile@gnu.org X-Mailman-Version: 2.1.14 Precedence: list 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-bounces+guile-bugs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.bugs:5782 Archived-At: Hi David, I fixed it! On Tue 12 Jul 2011 03:25, David Pirotte writes: > it only works the first time! This was the clue. Here's the commit log: fix order of importing modules and resolving duplicates handlers * module/ice-9/boot-9.scm (define-module*): Resolve duplicates handlers only after importing modules. Fixes a bug in which a module with #:use-module (oop goops) but whose merge-generics handler got resolved to noop instead of the real merge-generics handler. I can't think of an easy way to test this, though. Thanks to David Pirotte for the report! It worked the first time because the define-module form got evaluated twice: once during expand and once during eval (or load, for the compiled case). So the second evaluation it resolved merge-generics correctly. But, when loading from .go, there is no expansion, so there was just the one define-module* invocation, which exposed this ordering issue. Unfortunately this is very difficult to put into a test suite because it relies on Goops *not* being loaded when define-module* is called. Perhaps someone will come up with a nice test case, perhaps involving a direct call to define-module* from a standalone test case. Sorry the fix took so long, and thanks for the debugging. Cheers! Andy -- http://wingolog.org/