emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master 30d4011b8a: Use substitute-command-keys in Info-index error


From: Eli Zaretskii
Subject: master 30d4011b8a: Use substitute-command-keys in Info-index error
Date: Sat, 26 Nov 2022 16:10:02 +0200

> From: emacs-diffs-request@gnu.org
> Date: Sat, 26 Nov 2022 03:56:27 -0500
> 
> diff --git a/lisp/info.el b/lisp/info.el
> index 8860a664bd..7d44a1cec1 100644
> --- a/lisp/info.el
> +++ b/lisp/info.el
> @@ -3329,6 +3329,12 @@ If FILE is nil, check the current Info file."
>      (or node (error "No index"))
>      (Info-goto-node node)))
>  
> +(defun info--ensure-not-in-directory-node ()
> +  (if (equal Info-current-file "dir")
> +      (error (substitute-command-keys
> +              (concat "The Info directory node has no index; "
> +                      "type \\[Info-menu] to select a manual")))))

The new code doesn't handle the case where "DIR" is in upper-case, nor if
Info-current-file is something like "/usr/share/info/dir" (which can happen
if you say "C-u C-h i /usr/share/info/dir RET").

(Yes, the original code didn't handle these cases either.)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]