From: Michael Albinus <michael.albinus@gmx.de>
To: martin rudalics <rudalics@gmx.at>
Cc: Lars Ingebrigtsen <larsi@gnus.org>,
37745@debbugs.gnu.org, Eduardo Ochs <eduardoochs@gmail.com>
Subject: bug#37745: (save-window-excursion (shell) (buffer-name (current-buffer)))
Date: Thu, 17 Oct 2019 18:50:00 +0200 [thread overview]
Message-ID: <87pniv5nbb.fsf@gmx.de> (raw)
In-Reply-To: <bcc9eb53-252c-c210-ef6c-cf43c5561d68@gmx.at> (martin rudalics's message of "Thu, 17 Oct 2019 10:26:42 +0200")
martin rudalics <rudalics@gmx.at> writes:
>>> In many versions of Emacs the sexp below
>>>
>>> (save-window-excursion (shell) (buffer-name (current-buffer)))
>>>
>>> returns "*shell*", but in some recent versions it returns the name of
>>> the current buffer instead.
>>
>> This seems to be introduced by
>>
>> commit 59191cd0cbe8463f9095a71cb4048bb138d6e446
>> Author: Michael Albinus <michael.albinus@gmx.de>
>> Date: Sun Apr 2 11:02:54 2017 +0200
>>
>> Apply connecion-local variables for shells
>>
>> if I read the log right.
>>
>> It wraps the `pop-to-buffer' in a `(with-current-buffer buffer', so
>> current-buffer doesn't change like it used to.
>
> Why can't you simply use (buffer-name (shell)) instead?
That's possible, of course.
However, `shell' has always made the shell buffer current. It was an
oversight by me to change this.
I've added this behavior to the docstring of `shell', and fixed
this. Committed to master.
> martin
Best regards, Michael.
next prev parent reply other threads:[~2019-10-17 16:50 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-14 7:55 bug#37745: (save-window-excursion (shell) (buffer-name (current-buffer))) Eduardo Ochs
2019-10-17 3:03 ` Lars Ingebrigtsen
2019-10-17 8:26 ` martin rudalics
2019-10-17 16:50 ` Michael Albinus [this message]
2019-10-27 8:42 ` Michael Albinus
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=87pniv5nbb.fsf@gmx.de \
--to=michael.albinus@gmx.de \
--cc=37745@debbugs.gnu.org \
--cc=eduardoochs@gmail.com \
--cc=larsi@gnus.org \
--cc=rudalics@gmx.at \
/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.