GNU bug report logs - #31660
26.1.50; EIEIO manual's Quick Start example makes Emacs unusable

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Severity: minor; Reported by: Gemini Lasswell <gazally@HIDDEN>; Keywords: fixed confirmed; merged with #32595; Done: Noam Postavsky <npostavs@HIDDEN>; Maintainer for emacs is bug-gnu-emacs@HIDDEN.
bug marked as fixed in version 26.2, send any further explanations to 31660 <at> debbugs.gnu.org and Gemini Lasswell <gazally@HIDDEN> Request was from Noam Postavsky <npostavs@HIDDEN> to control <at> debbugs.gnu.org. Full text available.
Added tag(s) fixed. Request was from Noam Postavsky <npostavs@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 31660 <at> debbugs.gnu.org:


Received: (at 31660) by debbugs.gnu.org; 9 Apr 2019 23:10:32 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Apr 09 19:10:32 2019
Received: from localhost ([127.0.0.1]:52145 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hDzst-0001mI-JR
	for submit <at> debbugs.gnu.org; Tue, 09 Apr 2019 19:10:31 -0400
Received: from mail-qk1-f178.google.com ([209.85.222.178]:34332)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <npostavs@HIDDEN>)
 id 1hDzsr-0001lx-6U; Tue, 09 Apr 2019 19:10:29 -0400
Received: by mail-qk1-f178.google.com with SMTP id n68so106884qka.1;
 Tue, 09 Apr 2019 16:10:29 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version;
 bh=4y2UKhUkvR56MH0qDihSkDxbSJiwGghSmlKSgkNtrpc=;
 b=trPeWibcH4c+n4mOFgSdaZl7q7Oav2hc7GqZlA8v5KI5fsdZr94H3E9tSaMsnNFx8J
 HwpopzlTbplWC+YtBqVHYjJBbQ0frghPvVWUT/xkjpga+av8X0GWA4TeOyx94oBRqC1O
 QSGrUcTusLa0H4HepnPRpVLoY01nxMgAYXrVuJWhNQQm4lzKycuDnSkm5ILWHW5HQV9T
 6Efun62Dzm41+8lXNduM+yS465qXlsEZ5T1us4LpGOefVp1ZYQABg1KrbrmbYwqMQpDe
 k7iDvfAkT7Umw1G0yOhps6uythdPrPWCviNIjEMglOVMD4KCz+uJ5FXL4C9YAdkpxcXS
 qiNw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to
 :message-id:user-agent:mime-version;
 bh=4y2UKhUkvR56MH0qDihSkDxbSJiwGghSmlKSgkNtrpc=;
 b=TDpWSouhqeGN08nuquclkJ9TS2ZzZHUWUDETuPJ3fUCMb1P9m3UaQYo11v7sKR9wAN
 JIUs6QXp7/1aPCJ2FT5Fou3pmTX3ZJTNRhHHb5vvi1UkuzZf1Nkx393H8vQdTtFDipNz
 HW9GfA8A1nkg2Tc1LtC91ED3dezuHm/hqVA5Pqamc8EpJZH46CrbhgOjodDNPt95x/uQ
 vEgdk+eoISCoi3i8rMWKnDAAq53NzokhvcPXCZQwLaDHkK9yUO87ltCnCmC4sxSx2Luc
 ZPwmP3AWXE889amqrVWCA2lw55EWmKDeCgaYS6uvXaGldfadt1LibMP3H9kbM17OwiGq
 TMCw==
X-Gm-Message-State: APjAAAUfObOM1hdbMPgGvmuoIUn+puqUqlZqDGXn0xlZdTDyY1FwMjPm
 rrdRC6SxkLLu5b0VwxgyX+pn5Jyq
X-Google-Smtp-Source: APXvYqxBg9NAbLjMSNBOfxdKLlOeqfDlM88aHu4hKBjCc6jxyfOxtaPpFeZBrqW+Hdkuu2dY09nu5Q==
X-Received: by 2002:a37:69c3:: with SMTP id
 e186mr10009975qkc.308.1554851423534; 
 Tue, 09 Apr 2019 16:10:23 -0700 (PDT)
Received: from minid (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34])
 by smtp.googlemail.com with ESMTPSA id
 s17sm21570000qtc.15.2019.04.09.16.10.22
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Tue, 09 Apr 2019 16:10:22 -0700 (PDT)
From: Noam Postavsky <npostavs@HIDDEN>
To: Gemini Lasswell <gazally@HIDDEN>
Subject: Re: bug#31660: 26.1.50;
 EIEIO manual's Quick Start example makes Emacs unusable
References: <87wovl3r4u.fsf@HIDDEN> <878t7wafb0.fsf@HIDDEN>
 <87a7m0rctv.fsf@HIDDEN>
Date: Tue, 09 Apr 2019 19:10:21 -0400
In-Reply-To: <87a7m0rctv.fsf@HIDDEN> (Gemini Lasswell's message of "Thu,
 22 Nov 2018 14:01:48 -0800")
Message-ID: <87v9zmbwrm.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 31660
Cc: 31660 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

tags 31660 fixed
close 31660 26.2
quit

Gemini Lasswell <gazally@HIDDEN> writes:
>
> Here's a patch to eieio.texi which makes the examples work, and adds a
> suggestion to check for name conflicts to the description of 'defclass':
  
> +When defining a class, @eieio{} overwrites any preexisting variable or
> +function bindings for the symbol @var{class-name}, which may lead to
> +undesired consequences.  Before naming a new class, you should check
> +for name conflicts.

I added another sentence here about using package prefixes, and pushed
to emacs-26.

8d2f1df51a 2019-04-09T18:53:43-04:00 "Address name conflicts in EIEIO documentation (bug#31660)"




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#31660; Package emacs. Full text available.

Message received at 31660 <at> debbugs.gnu.org:


Received: (at 31660) by debbugs.gnu.org; 22 Nov 2018 22:02:14 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Nov 22 17:02:14 2018
Received: from localhost ([127.0.0.1]:42771 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1gPx38-00051N-0I
	for submit <at> debbugs.gnu.org; Thu, 22 Nov 2018 17:02:14 -0500
Received: from aibo.runbox.com ([91.220.196.211]:37728)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <gazally@HIDDEN>) id 1gPx35-00051B-Jh
 for 31660 <at> debbugs.gnu.org; Thu, 22 Nov 2018 17:02:12 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=runbox.com; 
 s=rbselector1;
 h=Content-Type:MIME-Version:Message-ID:Date:References:
 In-Reply-To:Subject:Cc:To:From;
 bh=kNsU+rlEnNKBnAsu8snvPv3wbEgPkBrDer3AVYAAsJg=; b=mrl61U3HvOEF6lID+DVkNw4zVY
 459yiSF6PWDWQTVt+o34IM98270776/TQ4q+o8I/hSwJHOGJjtHfgappgC8Yd2QbTuUbY/fMNo70t
 FTU79ofiWBNM+531UPje4rxhXohxCyNehjwUy2pW2zc1qPTpAmbG/Tzmf1yANalvgJhbSQy03ZNso
 gORDMkYZLvxKd96Uw36hIWwsuORH2BuJ5I+cwzCXkfu4wA//RzpsDOPTpBZeQNbkfk9Lhy7hyaldm
 hwkbVwdfIztQo0v9L6lmXoqUroG7qpTP1JwpQWfR13XeSZ0luRoedgo/Dvf1suSpyTughWmHdXkN6
 rwLu+OVQ==;
Received: from [10.9.9.212] (helo=mailfront12.runbox.com)
 by mailtransmit02.runbox with esmtp (Exim 4.86_2)
 (envelope-from <gazally@HIDDEN>)
 id 1gPx33-0004fJ-OB; Thu, 22 Nov 2018 23:02:09 +0100
Received: by mailfront12.runbox.com with esmtpsa (uid:179284 )
 (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82)
 id 1gPx2r-00020X-BK; Thu, 22 Nov 2018 23:01:58 +0100
From: Gemini Lasswell <gazally@HIDDEN>
To: Noam Postavsky <npostavs@HIDDEN>
Subject: Re: bug#31660: 26.1.50;
 EIEIO manual's Quick Start example makes Emacs unusable
In-Reply-To: <878t7wafb0.fsf@HIDDEN> (Noam Postavsky's message of "Sat, 02
 Jun 2018 20:23:31 -0400")
References: <87wovl3r4u.fsf@HIDDEN> <878t7wafb0.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1.90 (gnu/linux)
Date: Thu, 22 Nov 2018 14:01:48 -0800
Message-ID: <87a7m0rctv.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="=-=-="
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 31660
Cc: 31660 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

--=-=-=
Content-Type: text/plain

Noam Postavsky <npostavs@HIDDEN> writes:

> Gemini Lasswell <gazally@HIDDEN> writes:
>
>> Definitely the name of the class in the examples in the manual should be
>> changed, so that the examples work.
>
> Yeah.

Here's a patch to eieio.texi which makes the examples work, and adds a
suggestion to check for name conflicts to the description of 'defclass':


--=-=-=
Content-Type: text/plain
Content-Disposition: inline;
 filename=0001-Address-name-conflicts-in-EIEIO-documentation-bug-31.patch

From 81fa42ad5ad73bb789ad3edc6e06c9d91edbc997 Mon Sep 17 00:00:00 2001
From: Gemini Lasswell <gazally@HIDDEN>
Date: Thu, 22 Nov 2018 13:00:03 -0800
Subject: [PATCH] Address name conflicts in EIEIO documentation (bug#31660)

* doc/misc/eieio.texi (Quick Start): Rename the class used in the
example from 'record' to 'person'.
(Building Classes): Advise user to check for name conflicts before
naming a class.  Add a missing apostrophe.
(Making New Objects): Correct grammar.  Rename the class used in the
example from 'record' to 'my-class'.
---
 doc/misc/eieio.texi | 49 +++++++++++++++++++++++++--------------------
 1 file changed, 27 insertions(+), 22 deletions(-)

diff --git a/doc/misc/eieio.texi b/doc/misc/eieio.texi
index 689ff72b72..1ad1733762 100644
--- a/doc/misc/eieio.texi
+++ b/doc/misc/eieio.texi
@@ -88,11 +88,11 @@ Quick Start
 use @eieio{} to create classes, methods for those classes, and
 instances of classes.
 
-Here is a simple example of a class named @code{record}, containing
+Here is a simple example of a class named @code{person}, containing
 three slots named @code{name}, @code{birthday}, and @code{phone}:
 
 @example
-(defclass record () ; No superclasses
+(defclass person () ; No superclasses
   ((name :initarg :name
          :initform ""
          :type string
@@ -106,23 +106,23 @@ Quick Start
    (phone :initarg :phone
           :initform ""
           :documentation "Phone number."))
-  "A single record for tracking people I know.")
+  "A class for tracking people I know.")
 @end example
 
 Each class can have methods, which are defined like this:
 
 @example
-(cl-defmethod call-record ((rec record) &optional scriptname)
-  "Dial the phone for the record REC.
+(cl-defmethod call-person ((pers person) &optional scriptname)
+  "Dial the phone for the person PERS.
 Execute the program SCRIPTNAME to dial the phone."
-  (message "Dialing the phone for %s"  (oref rec name))
+  (message "Dialing the phone for %s"  (oref pers name))
   (shell-command (concat (or scriptname "dialphone.sh")
                          " "
-                         (oref rec phone))))
+                         (oref pers phone))))
 @end example
 
 @noindent
-In this example, the first argument to @code{call-record} is a list,
+In this example, the first argument to @code{call-person} is a list,
 of the form (@var{varname} @var{classname}).  @var{varname} is the
 name of the variable used for the first argument; @var{classname} is
 the name of the class that is expected as the first argument for this
@@ -130,17 +130,17 @@ Quick Start
 
 @eieio{} dispatches methods based on the type of the first argument.
 You can have multiple methods with the same name for different classes
-of object.  When the @code{call-record} method is called, the first
+of object.  When the @code{call-person} method is called, the first
 argument is examined to determine the class of that argument, and the
 method matching the input type is then executed.
 
 Once the behavior of a class is defined, you can create a new
-object of type @code{record}.  Objects are created by calling the
+object of type @code{person}.  Objects are created by calling the
 constructor.  The constructor is a function with the same name as your
 class which returns a new instance of that class.  Here is an example:
 
 @example
-(setq rec (record :name "Eric" :birthday "June" :phone "555-5555"))
+(setq pers (person :name "Eric" :birthday "June" :phone "555-5555"))
 @end example
 
 @noindent
@@ -157,19 +157,19 @@ Quick Start
 method defined for it.  In this example it would look like this:
 
 @example
-(call-record rec)
+(call-person pers)
 @end example
 
 @noindent
 or
 
 @example
-(call-record rec "my-call-script")
+(call-person pers "my-call-script")
 @end example
 
 In these examples, @eieio{} automatically examines the class of
-@code{rec}, and ensures that the method defined above is called.  If
-@code{rec} is some other class lacking a @code{call-record} method, or
+@code{pers}, and ensures that the method defined above is called.  If
+@code{pers} is some other class lacking a @code{call-person} method, or
 some other data type, Emacs signals a @code{cl-no-applicable-method}
 error.  @ref{Signals}.
 
@@ -270,10 +270,15 @@ Building Classes
 the class as a symbol property of @var{class-name} (@pxref{Symbol
 Components,,,elisp,GNU Emacs Lisp Reference Manual}).
 
+When defining a class, @eieio{} overwrites any preexisting variable or
+function bindings for the symbol @var{class-name}, which may lead to
+undesired consequences.  Before naming a new class, you should check
+for name conflicts.
+
 The @var{class-name} symbol's variable documentation string is a
 modified version of the doc string found in @var{options-and-doc}.
 Each time a method is defined, the symbol's documentation string is
-updated to include the methods documentation as well.
+updated to include the method's documentation as well.
 
 The parent classes for @var{class-name} is @var{superclass-list}.
 Each element of @var{superclass-list} must be a class.  These classes
@@ -625,10 +630,10 @@ Class Options
 @node Making New Objects
 @chapter Making New Objects
 
-Suppose we have a simple class is defined, such as:
+Suppose we have defined a simple class, such as:
 
 @example
-(defclass record ()
+(defclass my-class ()
    ( ) "Doc String")
 @end example
 
@@ -636,10 +641,10 @@ Making New Objects
 It is now possible to create objects of that class type.
 
 Calling @code{defclass} has defined two new functions.  One is the
-constructor @var{record}, and the other is the predicate,
-@var{record}-p.
+constructor @var{my-class}, and the other is the predicate,
+@var{my-class}-p.
 
-@defun record object-name &rest slots
+@defun my-class object-name &rest slots
 
 This creates and returns a new object.  This object is not assigned to
 anything, and will be garbage collected if not saved.  This object
@@ -657,7 +662,7 @@ Making New Objects
 Example of creating an object from a class:
 
 @example
-(record :value 3 :reference nil)
+(my-class :value 3 :reference nil)
 @end example
 
 @end defun
-- 
2.18.1


--=-=-=--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#31660; Package emacs. Full text available.
Forcibly Merged 31660 32595. Request was from Glenn Morris <rgm@HIDDEN> to control <at> debbugs.gnu.org. Full text available.
Added tag(s) confirmed. Request was from Noam Postavsky <npostavs@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 31660 <at> debbugs.gnu.org:


Received: (at 31660) by debbugs.gnu.org; 3 Jun 2018 00:23:39 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Jun 02 20:23:39 2018
Received: from localhost ([127.0.0.1]:59672 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1fPGo7-0002H8-Gx
	for submit <at> debbugs.gnu.org; Sat, 02 Jun 2018 20:23:39 -0400
Received: from mail-io0-f195.google.com ([209.85.223.195]:33163)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <npostavs@HIDDEN>) id 1fPGo6-0002Gu-Lt
 for 31660 <at> debbugs.gnu.org; Sat, 02 Jun 2018 20:23:39 -0400
Received: by mail-io0-f195.google.com with SMTP id d185-v6so5979097ioe.0
 for <31660 <at> debbugs.gnu.org>; Sat, 02 Jun 2018 17:23:38 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version;
 bh=7vKxbQrX1u0xyyqKif0NPB04fq/rzRW0e9VJKZKIQeA=;
 b=cCO1oP4SUD4fLzj21TGbourZOaXqIbnvU7q/dNwyLjycdMnBGUNUVgNfepJB7rRHH4
 3DVXNRJvxiQeGuBoOAbZrlSbWzcUgUL/DQ7eUo1a2N3obZP5ATg9Gn06n0CmWrnTnecd
 FcLriBmmrVmBRPy11t8CVMaR+Z2f6h26l+Ov+0CRkoA3QF6vagzuUq7sLPR484vZ5wjt
 UaA/2yItxbcyfTpIXO1/RjXPXH1W551DgB9M/JwFhyhdxC3JgB9YGxa6wkvf4lJN2ubs
 7e1rP/esQu35pI75RZaB/k5hwt8uiCiZmaV3dy2YKBWMaDObJLI3sDAZxQ6B+7XSF5yV
 oYLg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to
 :message-id:user-agent:mime-version;
 bh=7vKxbQrX1u0xyyqKif0NPB04fq/rzRW0e9VJKZKIQeA=;
 b=Sa2cNl2S6IfVd4sndtLZGFv2U2KkMqRfS9pFRoPBQ7mYv5ywz5rSxjNY4FIEJ1Ou2C
 vqSSJahoBxKUFlJzZWG8DxG6hqS974MYgpJZWXP/FDvhSBIoZxqwJrmUiaj7h5oNUQv4
 wJ5m8jfMQZLw0FWmtu/NBoJZ1pnddAkaDCr9bqZ6FpWtNU8gY95vmybm/kKfvSyDj8g9
 yvPwJIhZkL2G+nhAjaMkMGltUV31o2XFnCK4EIQ8cE/e6JhMifwSqMUhfZfDTRVRcJgk
 V90pu198ndrxTMiygt02d/LicXo/mJSOLqwssPbq6kjJKfwkj3Fs+FuwvzjAQZ74BgLI
 202A==
X-Gm-Message-State: APt69E1H3D4galJunIS+gD72AdEL3vBnl8Yex2gFWNzqCAht8uW5p+S9
 l90yOhEvRsRN1+i0zu3vMXuPNw==
X-Google-Smtp-Source: ADUXVKKUAZE1rgQMrzxDU9VDMalA9vJkDTyfJrs3IJd4lQIGyJRsA6m1fTCPYALnyLHFYKGBTBqYRg==
X-Received: by 2002:a5e:8c15:: with SMTP id
 n21-v6mr11427221ioj.217.1527985413200; 
 Sat, 02 Jun 2018 17:23:33 -0700 (PDT)
Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34])
 by smtp.googlemail.com with ESMTPSA id
 r137-v6sm2869368ita.8.2018.06.02.17.23.32
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Sat, 02 Jun 2018 17:23:32 -0700 (PDT)
From: Noam Postavsky <npostavs@HIDDEN>
To: Gemini Lasswell <gazally@HIDDEN>
Subject: Re: bug#31660: 26.1.50;
 EIEIO manual's Quick Start example makes Emacs unusable
References: <87wovl3r4u.fsf@HIDDEN>
Date: Sat, 02 Jun 2018 20:23:31 -0400
In-Reply-To: <87wovl3r4u.fsf@HIDDEN> (Gemini Lasswell's message of "Wed,
 30 May 2018 12:00:49 -0700")
Message-ID: <878t7wafb0.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -1.7 (-)
X-Debbugs-Envelope-To: 31660
Cc: 31660 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.7 (--)

Gemini Lasswell <gazally@HIDDEN> writes:

> Definitely the name of the class in the examples in the manual should be
> changed, so that the examples work.

Yeah.

> Maybe it would also be a good idea for defclass to signal an error or
> at least give a warning message if it is asked to define a class with
> the same name as an existing function unless that function is from a
> previous class definition.

A warning would be okay I think.  An error is too much: if you were
developing a library and decided to change a function into a class, then
you wouldn't be able to reload the new version without restarting Emacs.





Information forwarded to bug-gnu-emacs@HIDDEN:
bug#31660; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 30 May 2018 19:01:49 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 30 15:01:49 2018
Received: from localhost ([127.0.0.1]:55412 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1fO6M1-0002H9-4W
	for submit <at> debbugs.gnu.org; Wed, 30 May 2018 15:01:49 -0400
Received: from eggs.gnu.org ([208.118.235.92]:55882)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <gazally@HIDDEN>) id 1fO6Lz-0002Gw-KL
 for submit <at> debbugs.gnu.org; Wed, 30 May 2018 15:01:48 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <gazally@HIDDEN>) id 1fO6Lt-0006dp-K5
 for submit <at> debbugs.gnu.org; Wed, 30 May 2018 15:01:42 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM,
 T_DKIM_INVALID autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:49381)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <gazally@HIDDEN>) id 1fO6Lt-0006da-HU
 for submit <at> debbugs.gnu.org; Wed, 30 May 2018 15:01:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46828)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <gazally@HIDDEN>) id 1fO6Ls-0006uO-C7
 for bug-gnu-emacs@HIDDEN; Wed, 30 May 2018 15:01:41 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <gazally@HIDDEN>) id 1fO6Ln-0006ZH-Dj
 for bug-gnu-emacs@HIDDEN; Wed, 30 May 2018 15:01:40 -0400
Received: from aibo.runbox.com ([91.220.196.211]:44440)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
 (Exim 4.71) (envelope-from <gazally@HIDDEN>) id 1fO6Ln-0006Yi-3Y
 for bug-gnu-emacs@HIDDEN; Wed, 30 May 2018 15:01:35 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=runbox.com; 
 s=rbselector1;
 h=Content-Type:MIME-Version:Message-ID:Date:Subject:To:From; 
 bh=XWYNPNRaK+Q8lln6iqygrz6bR1FQkxz0EGo+uNUZLhQ=; b=eFmBAYnxcoMH4OQpHngLb2/Un
 yFsl2Qo8ftVIKbGNXCIrJYZPZ7Qtj0jMWu55MYYxwC0VH1qodhnzLKyYQTv5bWJTOcQduxBRsRDAP
 bOGBdD8iGcykcmVRD3K+j67q70cuI3u4MPoyWl6tvqJmhr7o+DA04WFj6YQk3kLs3qhV8/CCOD4ge
 OAI0sBBilvzl4aGhOsTxHfps+ZqoKY/wFHkbdRdlfYTkvMD4Mz9N3KHs0dP7vSQOmK9YyA+/749gO
 0xyxnKBS9g3ngXodKOQWDuKcjif6IhwW0bLvpCF41ycoSufjXLMjxSes2I3xQoKtukBYrn9p1t0ao
 fnebCtnuw==;
Received: from [10.9.9.212] (helo=mailfront12.runbox.com)
 by mailtransmit03.runbox with esmtp (Exim 4.86_2)
 (envelope-from <gazally@HIDDEN>) id 1fO6Ll-0002GR-54
 for bug-gnu-emacs@HIDDEN; Wed, 30 May 2018 21:01:33 +0200
Received: from c-24-22-244-161.hsd1.wa.comcast.net ([24.22.244.161]
 helo=sockeye) by mailfront12.runbox.com with esmtpsa (uid:179284 )
 (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) id 1fO6LG-0000U6-0j
 for bug-gnu-emacs@HIDDEN; Wed, 30 May 2018 21:01:03 +0200
From: Gemini Lasswell <gazally@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: 26.1.50; EIEIO manual's Quick Start example makes Emacs unusable
Date: Wed, 30 May 2018 12:00:49 -0700
Message-ID: <87wovl3r4u.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
 [fuzzy]
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -4.1 (----)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -5.1 (-----)

The first example in the EIEIO manual defines a class called 'record'.
Evaluating this example changes the function definition of 'record',
which makes many Emacs commands produce errors, including find-file,
ielm, and report-emacs-bug.

To reproduce, with emacs -Q:

M-x info RET
Navigate to the Quick Start node in the EIEIO manual, and select
the (defclass record ...) example.
M-w
M-x ielm RET
(require 'eieio) RET
C-y RET

Result: *** IELM Error ***  Error during pretty-printing (bug in pp)

Definitely the name of the class in the examples in the manual should be
changed, so that the examples work.

Maybe it would also be a good idea for defclass to signal an error or
at least give a warning message if it is asked to define a class with
the same name as an existing function unless that function is from a
previous class definition.




Acknowledgement sent to Gemini Lasswell <gazally@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#31660; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Tue, 9 Apr 2019 23:15:02 UTC

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