unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Shuguang Sun via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: 59985@debbugs.gnu.org
Subject: bug#59985: 30.0.50; tag error of switch-to-prev-buffer-skip-p in window.el
Date: Mon, 12 Dec 2022 12:40:39 +0800	[thread overview]
Message-ID: <tencent_7BA673C0F52DCE85AC59E0695303BA237E07@qq.com> (raw)

Dear all,

In `switch-to-prev-buffer-skip-p` of window.el, the tag of `found` is
not throw but `tag`. It makes switch/delete buffer failed if set
`switch-to-prev-buffer-skip-regexp` to a list/cons.

Below is the diff.

```
diff --git a/lisp/window.el b/lisp/window.el
index a11293d372a..7d8ee48635a 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -4636,7 +4636,7 @@ switch-to-prev-buffer-skip-p
                     (catch 'found
                       (dolist (regexp switch-to-prev-buffer-skip-regexp)
                         (when (string-match-p regexp (buffer-name buffer))
-                          (throw 'tag t)))))))))
+                          (throw 'found t)))))))))
 
 (defun switch-to-prev-buffer (&optional window bury-or-kill)
   "In WINDOW switch to previous buffer.
```

Best Regards,
Shuguang

In GNU Emacs 30.0.50 (build 1, x86_64-w64-mingw32) of 2022-12-11 built
 on YJ190169
Repository revision: 85108d541217f0333860c4f86c3b16b4349f85a4
Repository branch: master
Windowing system distributor 'Microsoft Corp.', version 10.0.22621
System Description: Microsoft Windows 10 Home China (v10.0.2009.22621.900)

Configured using:
 'configure --without-pop --with-native-image-api
 --with-native-compilation --with-tree-sitter --without-compress-install
 '--program-transform-name=s/^ctags$/ctags.emacs/''

Configured features:
ACL DBUS GIF GMP GNUTLS HARFBUZZ JPEG JSON LCMS2 LIBXML2 MODULES
NATIVE_COMP NOTIFY W32NOTIFY PDUMPER PNG RSVG SOUND SQLITE3 THREADS TIFF
TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XPM ZLIB






             reply	other threads:[~2022-12-12  4:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-12  4:40 Shuguang Sun via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2022-12-14 15:10 ` bug#59985: 30.0.50; tag error of switch-to-prev-buffer-skip-p in window.el Eli Zaretskii

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=tencent_7BA673C0F52DCE85AC59E0695303BA237E07@qq.com \
    --to=bug-gnu-emacs@gnu.org \
    --cc=59985@debbugs.gnu.org \
    --cc=shuguang79@qq.com \
    /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 public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).