* bug#55885: 29.0.50; missed error message
@ 2022-06-10 7:26 Andreas Röhler
2022-06-10 9:57 ` Lars Ingebrigtsen
0 siblings, 1 reply; 8+ messages in thread
From: Andreas Röhler @ 2022-06-10 7:26 UTC (permalink / raw)
To: 55885
[-- Attachment #1: Type: text/plain, Size: 3736 bytes --]
The code below evaluates to nil, but should send an error:
(defvar foo-bar-baz
(cond
(t ()
(when foo-bar-baz nil))))
Emacs 28.1 tells as expected:
Debugger entered--Lisp error: (void-variable foo-bar-baz)
(if foo-bar-baz (progn nil))
(cond (t nil (if foo-bar-baz (progn nil))))
(defvar foo-bar-baz (cond (t nil (if foo-bar-baz (progn nil)))))
eval((defvar foo-bar-baz (cond (t nil (if foo-bar-baz (progn nil)))))
nil)
elisp--eval-last-sexp(nil)
eval-last-sexp(nil)
funcall-interactively(eval-last-sexp nil)
call-interactively(eval-last-sexp nil nil)
command-execute(eval-last-sexp)
------
In GNU Emacs 29.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
2.24.32, cairo version 1.16.0)
of 2022-06-04
Repository revision: fe6f1dfeb4ad4aaf517d1ac34435f3750f7f4569
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12013000
System Description: Ubuntu 20.04.4 LTS
Configured using:
'configure --with-modules -with-mailutils'
Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG JSON
LIBOTF LIBSELINUX LIBXML2 MODULES NOTIFY INOTIFY PDUMPER PNG RSVG
SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS X11 XDBE XIM
XINPUT2 XPM GTK2 ZLIB
Important settings:
value of $LANG: de_DE.UTF-8
locale-coding-system: utf-8-unix
Major mode: ELisp/d
Minor modes in effect:
tooltip-mode: t
global-eldoc-mode: t
eldoc-mode: t
show-paren-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
line-number-mode: t
indent-tabs-mode: t
transient-mark-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
Load-path shadows:
None found.
Features:
(shadow sort mail-extr emacsbug message mailcap yank-media rmc puny
dired dired-loaddefs rfc822 mml mml-sec password-cache epa derived epg
rfc6068 epg-config gnus-util text-property-search time-date mm-decode
mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader
sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
help-fns radix-tree cl-print debug backtrace help-mode find-func
cl-loaddefs cl-lib seq gv subr-x byte-opt bytecomp byte-compile cconv
iso-transl tooltip eldoc paren electric uniquify ediff-hook vc-hooks
lisp-float-type elisp-mode 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 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 nadvice
simple cl-generic indonesian philippine 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 emoji-zwj charscript charprop case-table
epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button
loaddefs faces cus-face macroexp files window text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget keymap
hashtable-print-readable backquote threads dbusbind inotify
dynamic-setting system-font-setting font-render-setting cairo
move-toolbar gtk x-toolkit xinput2 x multi-tty make-network-process
emacs)
Memory information:
((conses 16 141917 6454)
(symbols 48 29644 0)
(strings 32 64292 1986)
(string-bytes 1 1009077)
(vectors 16 12076)
(vector-slots 8 173860 12616)
(floats 8 23 35)
(intervals 56 253 5)
(buffers 992 13))
[-- Attachment #2: Type: text/html, Size: 5071 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#55885: 29.0.50; missed error message
2022-06-10 7:26 bug#55885: 29.0.50; missed error message Andreas Röhler
@ 2022-06-10 9:57 ` Lars Ingebrigtsen
2022-06-12 7:30 ` Andreas Röhler
2022-06-12 7:43 ` Andreas Röhler
0 siblings, 2 replies; 8+ messages in thread
From: Lars Ingebrigtsen @ 2022-06-10 9:57 UTC (permalink / raw)
To: Andreas Röhler; +Cc: 55885
Andreas Röhler <andreas.roehler@easy-emacs.de> writes:
> The code below evaluates to nil, but should send an error:
>
> (defvar foo-bar-baz
> (cond
> (t ()
> (when foo-bar-baz nil))))
>
> Emacs 28.1 tells as expected:
>
> Debugger entered--Lisp error: (void-variable foo-bar-baz)
I'm unable to reproduce the problem. Both Emacs 29 or 28.1 give an
error if I eval that expression.
Perhaps you have that variable defined somewhere else so that it doesn't
bug out for you?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#55885: 29.0.50; missed error message
2022-06-10 9:57 ` Lars Ingebrigtsen
@ 2022-06-12 7:30 ` Andreas Röhler
2022-06-12 10:13 ` Lars Ingebrigtsen
2022-06-12 7:43 ` Andreas Röhler
1 sibling, 1 reply; 8+ messages in thread
From: Andreas Röhler @ 2022-06-12 7:30 UTC (permalink / raw)
To: Lars Ingebrigtsen; +Cc: 55885
[-- Attachment #1: Type: text/plain, Size: 1204 bytes --]
Am 10.06.22 um 11:57 schrieb Lars Ingebrigtsen:
> Andreas Röhler<andreas.roehler@easy-emacs.de> writes:
>
>> The code below evaluates to nil, but should send an error:
>>
>> (defvar foo-bar-baz
>> (cond
>> (t ()
>> (when foo-bar-baz nil))))
>>
>> Emacs 28.1 tells as expected:
>>
>> Debugger entered--Lisp error: (void-variable foo-bar-baz)
> I'm unable to reproduce the problem. Both Emacs 29 or 28.1 give an
> error if I eval that expression.
>
> Perhaps you have that variable defined somewhere else so that it doesn't
> bug out for you?
>
Seems my example doesn't work. Herewith the original code considered
faulty from my init:
(defvar ar-emacs-dir
(cond ((boundp 'lisp-directory)
(replace-regexp-in-string "/[^/]+/$" "" lisp-directory))
((< (string-to-number (substring emacs-version 0 2)) 27)
(alt-emacsdir))
(t (progn (elisp-find-definition "featurep")
(replace-regexp-in-string "/[^/]+/$" ""
(file-name-directory (buffer-file-name))))
(when ar-emacs-dir (kill-buffer "fns.c")))))
From Emacs 29.0.50 it will evaluate
==> "MY_DIR/emacs-20220604"
[-- Attachment #2: Type: text/html, Size: 1999 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#55885: 29.0.50; missed error message
2022-06-10 9:57 ` Lars Ingebrigtsen
2022-06-12 7:30 ` Andreas Röhler
@ 2022-06-12 7:43 ` Andreas Röhler
2022-06-12 10:11 ` Lars Ingebrigtsen
1 sibling, 1 reply; 8+ messages in thread
From: Andreas Röhler @ 2022-06-12 7:43 UTC (permalink / raw)
To: Lars Ingebrigtsen; +Cc: 55885
[-- Attachment #1: Type: text/plain, Size: 701 bytes --]
Am 10.06.22 um 11:57 schrieb Lars Ingebrigtsen:
> Andreas Röhler<andreas.roehler@easy-emacs.de> writes:
>
>> The code below evaluates to nil, but should send an error:
>>
>> (defvar foo-bar-baz
>> (cond
>> (t ()
>> (when foo-bar-baz nil))))
>>
>> Emacs 28.1 tells as expected:
>>
>> Debugger entered--Lisp error: (void-variable foo-bar-baz)
> I'm unable to reproduce the problem. Both Emacs 29 or 28.1 give an
> error if I eval that expression.
>
> Perhaps you have that variable defined somewhere else so that it doesn't
> bug out for you?
>
Maybe a more suitable example:
(defvar ar-emacs-dir
(cond (t t)
(t
(when ar-emacs-dir ()))))
[-- Attachment #2: Type: text/html, Size: 1360 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#55885: 29.0.50; missed error message
2022-06-12 7:43 ` Andreas Röhler
@ 2022-06-12 10:11 ` Lars Ingebrigtsen
2022-06-12 10:47 ` Andreas Röhler
0 siblings, 1 reply; 8+ messages in thread
From: Lars Ingebrigtsen @ 2022-06-12 10:11 UTC (permalink / raw)
To: Andreas Röhler; +Cc: 55885
Andreas Röhler <andreas.roehler@easy-emacs.de> writes:
> Maybe a more suitable example:
>
> (defvar ar-emacs-dir
> (cond (t t)
> (t
> (when ar-emacs-dir ()))))
That doesn't give an error in either Emacs 28 nor Emacs 29.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#55885: 29.0.50; missed error message
2022-06-12 7:30 ` Andreas Röhler
@ 2022-06-12 10:13 ` Lars Ingebrigtsen
0 siblings, 0 replies; 8+ messages in thread
From: Lars Ingebrigtsen @ 2022-06-12 10:13 UTC (permalink / raw)
To: Andreas Röhler; +Cc: 55885
Andreas Röhler <andreas.roehler@easy-emacs.de> writes:
> Seems my example doesn't work. Herewith the original code considered faulty from
> my init:
>
> (defvar ar-emacs-dir
> (cond ((boundp 'lisp-directory)
> (replace-regexp-in-string "/[^/]+/$" "" lisp-directory))
> ((< (string-to-number (substring emacs-version 0 2)) 27)
> (alt-emacsdir))
> (t (progn (elisp-find-definition "featurep")
> (replace-regexp-in-string "/[^/]+/$" "" (file-name-directory
> (buffer-file-name))))
> (when ar-emacs-dir (kill-buffer "fns.c")))))
elisp-find-definition doesn't exist in the Emacs tree.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#55885: 29.0.50; missed error message
2022-06-12 10:11 ` Lars Ingebrigtsen
@ 2022-06-12 10:47 ` Andreas Röhler
2022-06-12 11:42 ` Lars Ingebrigtsen
0 siblings, 1 reply; 8+ messages in thread
From: Andreas Röhler @ 2022-06-12 10:47 UTC (permalink / raw)
To: Lars Ingebrigtsen; +Cc: 55885
[-- Attachment #1: Type: text/plain, Size: 3659 bytes --]
Am 12.06.22 um 12:11 schrieb Lars Ingebrigtsen:
> Andreas Röhler<andreas.roehler@easy-emacs.de> writes:
>
>> Maybe a more suitable example:
>>
>> (defvar ar-emacs-dir
>> (cond (t t)
>> (t
>> (when ar-emacs-dir ()))))
> That doesn't give an error in either Emacs 28 nor Emacs 29.
>
Hmm, but it should, or? The use of a previous undefined var in its own
definition should raise an error.
Unfortunately, have some difficulty translating my init-stuff into a
generic report.
Here is what I --gladly-- get when starting from v28, but no longer from
v29:
Debugger entered--Lisp error: (void-variable ar-emacs-dir)
(if ar-emacs-dir (progn (kill-buffer "fns.c")))
(cond ((boundp 'lisp-directory) (replace-regexp-in-string "/[^/]+/$"
"" lisp-directory)) ((< (string-to-number (substring emacs-version 0 2))
27) (alt-emacsdir)) (t (progn (elisp-find-definition "featurep")
(replace-regexp-in-string "/[^/]+/$" "" (file-name-directory
(buffer-file-name)))) (if ar-emacs-dir (progn (kill-buffer "fns.c")))))
(defvar ar-emacs-dir (cond ((boundp 'lisp-directory)
(replace-regexp-in-string "/[^/]+/$" "" lisp-directory)) ((<
(string-to-number (substring emacs-version 0 2)) 27) (alt-emacsdir)) (t
(progn (elisp-find-definition "featurep") (replace-regexp-in-string
"/[^/]+/$" "" (file-name-directory (buffer-file-name)))) (if
ar-emacs-dir (progn (kill-buffer "fns.c"))))))
eval-buffer(#<buffer *load*-897063> nil "/home/my-name/.gnu-emacs25"
nil t) ; Reading at buffer position 3749
load-with-code-conversion("/home/my-name/.gnu-emacs25"
"/home/my-name/.gnu-emacs25" nil nil)
load("/home/my-name/.gnu-emacs25")
(cond ((string-match "^23" emacs-version) (setq custom-file
(expand-file-name "~/.gnu-emacs23-cvs-custom")) (load (expand-file-name
"~/.gnu-emacs23-all-cvs"))) ((string-match "^24" emacs-version) (setq
custom-file (expand-file-name "~/.gnu-emacs24-custom")) (load
(expand-file-name "~/.gnu-emacs24"))) ((string-match "^25"
emacs-version) (setq custom-file (expand-file-name
"~/.gnu-emacs25-custom")) (load (expand-file-name "~/.gnu-emacs25")))
((string-match "^26" emacs-version) (setq custom-file (expand-file-name
"~/.gnu-emacs25-custom")) (load (expand-file-name "~/.gnu-emacs25")))
((string-match "^27" emacs-version) (setq custom-file (expand-file-name
"~/.gnu-emacs25-custom")) (load (expand-file-name "~/.gnu-emacs25")))
((string-match "^28" emacs-version) (setq custom-file (expand-file-name
"~/.gnu-emacs25-custom")) (load (expand-file-name "~/.gnu-emacs25")))
((string-match "^29" emacs-version) (setq custom-file (expand-file-name
"~/.gnu-emacs25-custom")) (load (expand-file-name "~/.gnu-emacs25"))))
eval-buffer(#<buffer *load*> nil "/home/my-name/.emacs" nil t) ;
Reading at buffer position 1480
load-with-code-conversion("/home/my-name/.emacs"
"/home/my-name/.emacs" t t)
load("~/.emacs" noerror nomessage)
startup--load-user-init-file(#f(compiled-function () #<bytecode
0xf76a6f1249f6a62>) #f(compiled-function () #<bytecode
-0x1f3c686ddc0cdc35>) t)
command-line()
normal-top-level()
;;; below again the code which --gladly-- triggered this:
(defvar ar-emacs-dir
(cond ((boundp 'lisp-directory)
(replace-regexp-in-string "/[^/]+/$" "" lisp-directory))
((< (string-to-number (substring emacs-version 0 2)) 27)
(alt-emacsdir))
(t (progn (elisp-find-definition "featurep")
(replace-regexp-in-string "/[^/]+/$" ""
(file-name-directory (buffer-file-name))))
(when ar-emacs-dir (kill-buffer "fns.c")))))
[-- Attachment #2: Type: text/html, Size: 4848 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#55885: 29.0.50; missed error message
2022-06-12 10:47 ` Andreas Röhler
@ 2022-06-12 11:42 ` Lars Ingebrigtsen
0 siblings, 0 replies; 8+ messages in thread
From: Lars Ingebrigtsen @ 2022-06-12 11:42 UTC (permalink / raw)
To: Andreas Röhler; +Cc: 55885
Andreas Röhler <andreas.roehler@easy-emacs.de> writes:
> (defvar ar-emacs-dir
> (cond (t t)
> (t
> (when ar-emacs-dir ()))))
>
> That doesn't give an error in either Emacs 28 nor Emacs 29.
>
> Hmm, but it should, or? The use of a previous undefined var in its own definition
> should raise an error.
Only if execution reaches that form, and it doesn't here because of the
`t' branch in the cond.
> Unfortunately, have some difficulty translating my init-stuff into a generic report.
>
> Here is what I --gladly-- get when starting from v28, but no longer from v29:
>
> Debugger entered--Lisp error: (void-variable ar-emacs-dir)
> (if ar-emacs-dir (progn (kill-buffer "fns.c")))
> (cond ((boundp 'lisp-directory) (replace-regexp-in-string "/[^/]+/$" "" lisp-directory))
lisp-directory is bound in Emacs 29 but not Emacs 28, so that branch of
the cond is taken there.
So this is all working as it should, and I'm closing this bug report.
(And you should consider using the Emacs help lists with things you
don't understand about Emacs Lisp instead of the bug tracker.)
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2022-06-12 11:42 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-06-10 7:26 bug#55885: 29.0.50; missed error message Andreas Röhler
2022-06-10 9:57 ` Lars Ingebrigtsen
2022-06-12 7:30 ` Andreas Röhler
2022-06-12 10:13 ` Lars Ingebrigtsen
2022-06-12 7:43 ` Andreas Röhler
2022-06-12 10:11 ` Lars Ingebrigtsen
2022-06-12 10:47 ` Andreas Röhler
2022-06-12 11:42 ` Lars Ingebrigtsen
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.