From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Andrea Corallo Newsgroups: gmane.emacs.devel Subject: Re: master 1d9d07fb00e 3/3: (cl--typeof-types): Rework to fix some regressions Date: Tue, 05 Mar 2024 04:34:13 -0500 Message-ID: References: <170950733941.30552.13228431602613197760@vcs2.savannah.gnu.org> <20240303230900.51D39C12C5F@vcs2.savannah.gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="8688"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Mar 05 10:34:25 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rhRBp-0001zH-8y for ged-emacs-devel@m.gmane-mx.org; Tue, 05 Mar 2024 10:34:25 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rhRBf-0001nz-OT; Tue, 05 Mar 2024 04:34:15 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rhRBe-0001nR-4L for emacs-devel@gnu.org; Tue, 05 Mar 2024 04:34:14 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rhRBd-0001fu-JM; Tue, 05 Mar 2024 04:34:13 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To: From; bh=Z1wPzlt5EJfcfzteUoOMSAtgBvu+5Opc7jPzsN0NTCg=; b=PoOHwIio2kMPHGL55zr4 ZaZ/LSQVDC+DcUV/ytTeej/z0Xt9qF9u20p4xJYGWDZ98hUaoK4c4clE0/jJIbqyeiwYd8XxUKM94 LSFSwWDo4bVGHn18JZdNfoTM97RU/cVJYNpwy1tvA+q0sRJ5fw1YvtgfV+X1MqsCpaGDjkkYgQwHN Z3u9L+7KdnEK0GwN7DA9fMLIqFDnPNHiGA74tQWOXrMfq0vZe9hfZBCERIL++0Q/q741nGALh1jQr XFxjHi3u9MUgzfV8mqQLsK3zZAMxub5iEjVwlY5zevrPRzrSGzlt6rSamywq7raK5gvbsCpfRZdBK R7ftZdThYMKPxQ==; Original-Received: from acorallo by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1rhRBd-00053C-CC; Tue, 05 Mar 2024 04:34:13 -0500 In-Reply-To: (Stefan Monnier's message of "Mon, 04 Mar 2024 19:08:18 -0500") X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:316819 Archived-At: Stefan Monnier writes: >>>>> I'm not sure I understand. Is some code relying on the "order" of the >>>>> supertypes? Are these the regression you are mentioning? >>>>> Must say I'm surprised supertypes can have an "order" in first place. >>> Hmm... a lot of what I've been talking about in this thread is about the >>> order of parents in `cl--typeof-types`, so yes, the order is important. >>> It determines the priority between methods. >> I'm asking because I'd personally consider any program relying on of the >> parent order just buggy. > > Such dependencies are rare, indeed. They're rare enough that I wouldn't > have enough intuition to judge whether they reflect bugs or not. In any > case CLOS wants it, and I see no reason to do otherwise: the cl-generic > code needs to order the methods according to some criteria, so I prefer > to document that we do it like CLOS than to make it "undefined" (it'd be > extra work to try and detect such undefined cases, on top of that, so > instead we'd get "some arbitrary order" (like we have now) which we'd > have to preserve to avoid breaking backward compatibility: might as well > make this arbitrary order somewhat meaningful =F0=9F=99=82). Makes sense now, thanks for the fix :) Andrea