From: Philip Kaludercic <philipk@posteo.net>
To: Juri Linkov <juri@linkov.net>
Cc: 54374@debbugs.gnu.org
Subject: bug#54374: 29.0.50; previous-completion fails at beginning of completions buffer
Date: Sun, 13 Mar 2022 20:39:53 +0000 [thread overview]
Message-ID: <871qz5k2na.fsf@posteo.net> (raw)
In-Reply-To: <86h782b3zk.fsf@mail.linkov.net> (Juri Linkov's message of "Sun, 13 Mar 2022 19:39:13 +0200")
[-- Attachment #1: Type: text/plain, Size: 195 bytes --]
Juri Linkov <juri@linkov.net> writes:
> X-Debbugs-Cc: Philip Kaludercic <philipk@posteo.net>
>
> This is not reproducible in Emacs 28, so looks like a recent regression:
This seems to fix it:
[-- Attachment #2: Type: text/plain, Size: 595 bytes --]
diff --git a/lisp/simple.el b/lisp/simple.el
index accc119e2b..7d47aba1ee 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -9125,7 +9125,7 @@ next-completion
(unless (get-text-property (point) 'mouse-face)
(goto-char (next-single-property-change (point) 'mouse-face nil end)))
(setq n (1- n)))
- (while (< n 0)
+ (while (and (< n 0) (< 1 (point)))
(let ((prop (get-text-property (1- (point)) 'mouse-face)))
;; If in a completion, move to the start of it.
(when (and prop (eq prop (get-text-property (point) 'mouse-face)))
[-- Attachment #3: Type: text/plain, Size: 495 bytes --]
> 0. emacs -Q
> 1. M-x TAB
> 2. move point to the beginning of the *Completions* buffer
> 3. type S-TAB (<backtab>)
>
> Debugger entered--Lisp error: (args-out-of-range 0 0)
> get-text-property(0 mouse-face)
> next-completion(-1)
> previous-completion(1)
> funcall-interactively(previous-completion 1)
> command-execute(previous-completion)
> completing-read-default("M-x " ...)
> read-extended-command()
> command-execute(execute-extended-command)
>
>
--
Philip Kaludercic
next prev parent reply other threads:[~2022-03-13 20:39 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-13 17:39 bug#54374: 29.0.50; previous-completion fails at beginning of completions buffer Juri Linkov
2022-03-13 20:39 ` Philip Kaludercic [this message]
2022-03-14 3:22 ` Eli Zaretskii
2022-03-14 8:20 ` Philip Kaludercic
2022-03-14 12:59 ` Eli Zaretskii
2022-03-14 13:34 ` Philip Kaludercic
2022-03-14 8:35 ` Andreas Schwab
2022-03-14 8:30 ` Juri Linkov
2022-03-14 14:12 ` Philip Kaludercic
2022-03-14 18:24 ` Juri Linkov
2022-03-18 21:49 ` Philip Kaludercic
2022-03-19 19:13 ` Juri Linkov
2022-05-24 19:12 ` Juri Linkov
2022-05-26 16:26 ` Juri Linkov
2022-05-27 16:13 ` Juri Linkov
2022-03-24 18:11 ` Juri Linkov
2022-03-14 15:21 ` bug#54374: [External] : " Drew Adams
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=871qz5k2na.fsf@posteo.net \
--to=philipk@posteo.net \
--cc=54374@debbugs.gnu.org \
--cc=juri@linkov.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.