unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* How do I find out, in a Lisp program, what is the current buffer?
@ 2023-12-05 14:35 Alan Mackenzie
  2023-12-05 15:03 ` Eshel Yaron
  0 siblings, 1 reply; 3+ messages in thread
From: Alan Mackenzie @ 2023-12-05 14:35 UTC (permalink / raw)
  To: emacs-devel

Hello, Emacs.

I want to find out what is the current buffer, and I mean the REAL
current buffer.

In particular, if that is the minibuffer, I want to be told it's the (or
a) minibuffer, not the buffer it was invoked from.  The function
current-buffer won't do this.

I want to use this for writing the current buffer into the new position
info in the doc string (bug #67455).  Evaluating a defun in the
minibuffer is different from evaluating one in *scratch*.

Is there some way I can get this information from Lisp, or do I have to
write a new C primitive?

Thanks in advance!

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-12-05 15:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-05 14:35 How do I find out, in a Lisp program, what is the current buffer? Alan Mackenzie
2023-12-05 15:03 ` Eshel Yaron
2023-12-05 15:20   ` Alan Mackenzie

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).