From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#43621: 28.0.50; Clean up EIEIO Date: Fri, 25 Sep 2020 16:53:01 -0400 Message-ID: References: <87ft751vs5.fsf@web.de> 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="16225"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: eric@ericabrahamsen.net, 43621@debbugs.gnu.org To: Michael Heerdegen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Sep 25 22:54:10 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1kLujJ-00049e-U9 for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 25 Sep 2020 22:54:10 +0200 Original-Received: from localhost ([::1]:52230 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kLujI-0000q4-VM for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 25 Sep 2020 16:54:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:51134) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kLujC-0000pv-78 for bug-gnu-emacs@gnu.org; Fri, 25 Sep 2020 16:54:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33900) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kLujB-00079e-Ub for bug-gnu-emacs@gnu.org; Fri, 25 Sep 2020 16:54:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kLujB-0001AR-U8 for bug-gnu-emacs@gnu.org; Fri, 25 Sep 2020 16:54:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 25 Sep 2020 20:54:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 43621 X-GNU-PR-Package: emacs X-Debbugs-Original-Cc: Eric Abrahamsen , bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.16010671954430 (code B ref -1); Fri, 25 Sep 2020 20:54:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 25 Sep 2020 20:53:15 +0000 Original-Received: from localhost ([127.0.0.1]:45446 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kLuiR-00019O-HQ for submit@debbugs.gnu.org; Fri, 25 Sep 2020 16:53:15 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:46890) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kLuiP-00019G-ME for submit@debbugs.gnu.org; Fri, 25 Sep 2020 16:53:14 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50942) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kLuiP-0000os-BB for bug-gnu-emacs@gnu.org; Fri, 25 Sep 2020 16:53:13 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:26811) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kLuiM-000766-VD for bug-gnu-emacs@gnu.org; Fri, 25 Sep 2020 16:53:12 -0400 Original-Received: from pmg1.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id 72C0D100272; Fri, 25 Sep 2020 16:53:09 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id 93A0A10022D; Fri, 25 Sep 2020 16:53:07 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1601067187; bh=vxNuMw7T6wFvfoV3i1YVsf9U0XPrVtoB9KZs34JlKK0=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=egryTPH+kfXFB8f1EWNHmGBAE9jliRa66w+mQ4bdccheiJzln1tdAwq/4xG0Dj3DR ho8p2LPXCeLsdgF0qdWSzvq1udJ8Zm1KmBE+dYrv6xUAyeHmOp5p432URoOS9eF6LP 55OzUTKLpSD6DKOaJfZTY74Yw6FdEZgxGLzArCBtmPDSLXOZ3t+ovGBBjONWFLfHkZ 9N3jUWQN+JHza0dQuvo9ZogYwkXTUIUXbrOi23M5G551ZeOjPJH6u/9LBISghXzJin 8Wyqz3HZHjJ4+HNAar3x6pRP/gOotAQjFC2MMklvBv086ghOLgTZrSR25wFHN1LwL6 1iUMFz722MuVg== Original-Received: from alfajor (unknown [45.72.232.131]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 688FA1202CD; Fri, 25 Sep 2020 16:53:07 -0400 (EDT) In-Reply-To: <87ft751vs5.fsf@web.de> (Michael Heerdegen's message of "Fri, 25 Sep 2020 21:49:46 +0200") Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/25 16:32:33 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:188996 Archived-At: > I'm currently seriously learning and using EIEIO for the first time. > Here are my findings (so far): > > (1) Manual > > (1a) (info "(eieio) Introduction") > > | Method dispatch > | EIEO does not support method dispatch for built-in types and > | multiple arguments types. In other words, method dispatch only > | looks at the first argument, and this one must be an EIEIO type. > > What's said about dispatching only looking at the first argument is not > true anymore, right? And Indeed. EIEIO's method dispatch has been thrown away, and instead cl-generic.el provides it separately from EIEIO. IOW nowadays "EIEIO" refers to the facilities surrounding `defclass` but not method dispatch any more. Also: cl-generic *can* dispatch on built-in types (and defstruct types). > | =E2=80=98:around=E2=80=99 method tag > | This CLOS method tag is non-functional. > Also not correct any more, right? > That whole paragraph should be overhauled and adapted to the obviously > new state of the code I guess. And moved out of `eieio.texi`. > | Whenever defclass is used to create a new class, a predicate is created > | for it, named =E2=80=98CLASS-NAME-p=E2=80=99: > |=20 > | -- Function: CLASS-NAME-p object > | Return non-=E2=80=98nil=E2=80=99 if and only if OBJECT is of the c= lass CLASS-NAME. > > I found it surprising that the predicate fails for instances of classes > that inherit from CLASS-NAME. If this is intended, I guess this should > be mentioned...? Indeed. It might also be better to promote `(cl-typep EXP ')` instead of `-p`, which behaves in the more "normal" way. > (2) `info-lookup' doesn't work for eieio functions. I guess it should? It would be nice to make it work, yes. > (3) Doc of `defclass': > | :writer - A function symbol which will `write' an object's slot. > I find "`write'" confusing: there is no function `write' (so why quote > it like this?), and it should better be "set" anyway, since in other > places (in eieio!) "write" is used as synonym for "print". Agreed. It should also be improved to clarify what arguments the writer takes (IIUC the writer function will take 2 args (the object and a value for the slot), so the doc needs to clarify in which order those args are supposed to come). > Some love is needed here. Can you provide that love? Stefan