GNU bug report logs - #47747
28.0.50; `eval-defun' may evaluate previous sexp

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; Reported by: sebastian.miele@HIDDEN; dated Tue, 13 Apr 2021 11:48:01 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

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


Received: (at 47747) by debbugs.gnu.org; 5 May 2021 16:10:15 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 05 12:10:15 2021
Received: from localhost ([127.0.0.1]:33080 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1leK6I-0003rm-O8
	for submit <at> debbugs.gnu.org; Wed, 05 May 2021 12:10:14 -0400
Received: from quimby.gnus.org ([95.216.78.240]:38660)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1leK6G-0003rY-Pz
 for 47747 <at> debbugs.gnu.org; Wed, 05 May 2021 12:10:13 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=Giy3Tr2IxFf2uyMRxIpDLGWTccZLNojUsGlCrUNKNv0=; b=c0dOSjOqz5ii0ZE6qi80EPaV4b
 zMDvKcaXQiJIU7AA72GzmOXOUXat9vU/KnLPBEmecYpDl2zxdZtMTB9+4ORuaB1qK25X6y+jm3HeB
 mpZ+83ATU8Kd6Emvi1IhkvDsudmc95Ib5mbZgI23PiQh3ywY+GEI8ir/M0ll0D7CVBjw=;
Received: from cm-84.212.220.105.getinternet.no ([84.212.220.105] helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1leK66-0003Rh-W5; Wed, 05 May 2021 18:10:05 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Sebastian Miele <sebastian.miele@HIDDEN>
Subject: Re: bug#47747: 28.0.50; `eval-defun' may evaluate previous sexp
References: <87im4qque5.fsf@HIDDEN>
X-Now-Playing: Martina Topley-Bird's _Quixotic_: "Anything"
Date: Wed, 05 May 2021 18:10:02 +0200
In-Reply-To: <87im4qque5.fsf@HIDDEN> (Sebastian Miele's message of "Tue, 13
 Apr 2021 13:46:42 +0200")
Message-ID: <87mtt92mcl.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview:  Sebastian Miele <sebastian.miele@HIDDEN> writes: > With
 emacs -Q, a *scratch* buffer of > > ;; start of buffer > (error "") > ;;
 !!! point somewhere here !!! > ; ; end of buffer > > and point where indicated,
 invoking `eval-defun' (C-M-x) evaluates t [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 47747
Cc: 47747 <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 (-)

Sebastian Miele <sebastian.miele@HIDDEN> writes:

> With emacs -Q, a *scratch* buffer of
>
>   ;; start of buffer
>   (error "")
>   ;; !!! point somewhere here !!!
>   ;; end of buffer
>
> and point where indicated, invoking `eval-defun' (C-M-x) evaluates the
> expression (error "").
>
> Expected: An error indicating that there is no top-level form containing
> point, or after point.  (From `eval-defun's docstring: "Evaluate the
> top-level form containing point, or after point.")

If there are no forms after point, it'll eval the form before point --
and it's been that way for as long as I can remember, so I think the doc
string is just wrong here.

Does anybody else have an opinion here?  Would it make sense to have the
command signal an error if there's no forms at or after point?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




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

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


Received: (at submit) by debbugs.gnu.org; 13 Apr 2021 11:47:05 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Apr 13 07:47:05 2021
Received: from localhost ([127.0.0.1]:59108 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1lWHVZ-0001bD-FM
	for submit <at> debbugs.gnu.org; Tue, 13 Apr 2021 07:47:05 -0400
Received: from lists.gnu.org ([209.51.188.17]:38802)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <sebastian.miele@HIDDEN>) id 1lWHVY-0001b5-16
 for submit <at> debbugs.gnu.org; Tue, 13 Apr 2021 07:47:04 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:41524)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <sebastian.miele@HIDDEN>)
 id 1lWHVT-0004OP-OS
 for bug-gnu-emacs@HIDDEN; Tue, 13 Apr 2021 07:47:03 -0400
Received: from mail-ed1-x52e.google.com ([2a00:1450:4864:20::52e]:44948)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1) (envelope-from <sebastian.miele@HIDDEN>)
 id 1lWHVL-0001aW-Rs
 for bug-gnu-emacs@HIDDEN; Tue, 13 Apr 2021 07:46:59 -0400
Received: by mail-ed1-x52e.google.com with SMTP id f8so19003336edd.11
 for <bug-gnu-emacs@HIDDEN>; Tue, 13 Apr 2021 04:46:45 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=user-agent:from:to:subject:reply-to:message-id:date:mime-version;
 bh=iPTPApvTzLNK1MfKfZohqVl1GLjheQzxwQsoiSlzTT0=;
 b=kqxo8UGktgcrpYlS1l6D5uq0u3hVqy/aO4arrjcZq3/v2/847LKuw1AJTe+ZnMUXQY
 QG/Jdz/RSSlK/uyHRSyOJtEXoZ3Z/PvQpw9Y7c+trACQ5cGSwU0DgYJdE1lC852FxhuP
 tlbK7wZO+8LB2HJ3r0tOuhgBnVzOEL7xoCOYgwdbxV/pLHwW3kK8xPF+p1PfXbmPfP9Z
 ZW1xxqgzBdH4gTmPEr/eTQwTNANqQSvCKHIZOd78ysK61rkw3ARJSQU/L1an63ZtjtaV
 Mn6wyTKK03DKfaIfqQCkI94q6dNLY5Rw2voKu2Jm5zl3oShg8ZF3XTgMzzZBeVcbpNkP
 znPw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:user-agent:from:to:subject:reply-to:message-id
 :date:mime-version;
 bh=iPTPApvTzLNK1MfKfZohqVl1GLjheQzxwQsoiSlzTT0=;
 b=Wdz8xKRegvGyGoaZc4ZF9pa5r3fVFkQfEe0irKWQpvlgCmd/a5rr2NkWdSmSL0++Hj
 GwgA81Bs3zYvtIejkMDrgRsidvG/iOkXx9jiB3//+HGWe/ilN1lP7VYepH2OnlA2okAR
 ucmL7fVurUzlv6FpHRq33f2QF7rDNBucQeCcDXl0jGyMm7LjO5oRyuNwVpYpjxRspbdi
 LCTODuKYDg6suEf/HiCvb39NtITzFMJmHLnS3gn5n37ehyUGDwKog/qenJtB/OcnbYnH
 5WtHdEj1ulLE/BvfD0X5KCjD6efImQe7UmlRoX1WyyOTouRUwneCGRTIr1hBaw2VyJg8
 eWLw==
X-Gm-Message-State: AOAM532+YruJc+7k9DpWoVTAGsO8WZAzft0Lz4VciRu/36Y/FZ1kiV1B
 rnIihvHpHIUf7OAzXAKPqSpq9/IQQmg=
X-Google-Smtp-Source: ABdhPJwyen/p4yXsHCQHR/RVm9+ZBc39Zv303hBheFJ7A15PH36uxkbvFTMsHx1Ftn6h5Uz7krTi7g==
X-Received: by 2002:aa7:c9c8:: with SMTP id i8mr33820618edt.193.1618314404568; 
 Tue, 13 Apr 2021 04:46:44 -0700 (PDT)
Received: from huette ([5.146.118.192])
 by smtp.gmail.com with ESMTPSA id o17sm8898364edt.10.2021.04.13.04.46.43
 for <bug-gnu-emacs@HIDDEN>
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
 Tue, 13 Apr 2021 04:46:43 -0700 (PDT)
User-agent: mu4e 1.4.15; emacs 27.2
From: Sebastian Miele <sebastian.miele@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: 28.0.50; `eval-defun' may evaluate previous sexp
Message-ID: <87im4qque5.fsf@HIDDEN>
Date: Tue, 13 Apr 2021 13:46:42 +0200
MIME-Version: 1.0
Content-Type: text/plain
Received-SPF: pass client-ip=2a00:1450:4864:20::52e;
 envelope-from=sebastian.miele@HIDDEN; helo=mail-ed1-x52e.google.com
X-Spam_score_int: -20
X-Spam_score: -2.1
X-Spam_bar: --
X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001,
 RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: -1.3 (-)
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>
Reply-To: sebastian.miele@HIDDEN
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.3 (--)

With emacs -Q, a *scratch* buffer of

  ;; start of buffer
  (error "")
  ;; !!! point somewhere here !!!
  ;; end of buffer

and point where indicated, invoking `eval-defun' (C-M-x) evaluates the
expression (error "").

Expected: An error indicating that there is no top-level form containing
point, or after point.  (From `eval-defun's docstring: "Evaluate the
top-level form containing point, or after point.")

This is also happens in Emacs 27.2.

In GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.28, cairo version 1.17.4)
 of 2021-04-13 built on huette
Repository revision: 6de79542e43ece9a12ebc032c275a6c3fee0b73b
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12010000
System Description: Arch Linux

Configured using:
 'configure --with-x-toolkit=gtk3 --with-mailutils --with-cairo'

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
JSON LCMS2 LIBOTF LIBSYSTEMD LIBXML2 M17N_FLT MODULES NOTIFY INOTIFY
PDUMPER PNG RSVG SECCOMP SOUND THREADS TIFF TOOLKIT_SCROLL_BARS X11 XDBE
XIM XPM GTK3 ZLIB

Important settings:
  value of $LC_CTYPE: de_DE.UTF-8
  value of $LANG: C
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
rfc822 mml mml-sec epa derived epg epg-config gnus-util rmail
rmail-loaddefs auth-source cl-seq eieio eieio-core cl-macs
eieio-loaddefs password-cache json map text-property-search time-date
subr-x seq byte-opt gv bytecomp byte-compile cconv mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader cl-loaddefs
cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
iso-transl tooltip eldoc electric uniquify ediff-hook vc-hooks
lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar
dnd fontset image regexp-opt fringe tabulated-list replace newcomment
text-mode elisp-mode lisp-mode prog-mode register page tab-bar menu-bar
rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock
font-lock syntax font-core term/tty-colors frame minibuffer cl-generic
cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech
european ethiopic indian cyrillic chinese composite charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray
cl-preloaded nadvice button loaddefs faces cus-face macroexp files
window text-properties overlay sha1 md5 base64 format env code-pages
mule custom widget hashtable-print-readable backquote threads dbusbind
inotify lcms2 dynamic-setting system-font-setting font-render-setting
cairo move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)

Memory information:
((conses 16 50702 9549)
 (symbols 48 6499 1)
 (strings 32 18069 1461)
 (string-bytes 1 598156)
 (vectors 16 13126)
 (vector-slots 8 174449 10296)
 (floats 8 23 37)
 (intervals 56 229 0)
 (buffers 992 12))




Acknowledgement sent to sebastian.miele@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#47747; 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: Wed, 5 May 2021 16:15:01 UTC

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