all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#65414: save-some-buffers-functions are unexpectedly called when save-some-buffers pred is non-nil
@ 2023-08-21  4:06 Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-08-21 11:56 ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2023-08-21  4:06 UTC (permalink / raw)
  To: 65414; +Cc: jonas

Functions which are added to save-some-buffers-functions are always
called when save-some-buffers runs, even when a PRED argument is
specified. This leads to unexpected behavior when PRED is intended to
limit saving buffers to a specific set of file buffers, as in Magit's
magit-save-repository-buffers function.

abbrev--possibly-save is added to save-some-buffers-functions by default
now, so whenever magit-save-repository-buffers runs, Emacs prompts to
save unsaved abbrevs (as well any other functions in the list).

I propose that we pass along the PRED argument of save-some-buffers to
each of save-some-buffers-functions, allowing them to determine what is
appropriate to do. Alternatively, we could pass along the return value
of files--buffers-needing-to-be-saved, which is a list of buffers.

Thoughts?

Joseph





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

end of thread, other threads:[~2023-09-04 15:59 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-21  4:06 bug#65414: save-some-buffers-functions are unexpectedly called when save-some-buffers pred is non-nil Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-21 11:56 ` Eli Zaretskii
2023-08-23 23:57   ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24  5:16     ` Eli Zaretskii
2023-08-26  6:38       ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-26  7:26         ` Eli Zaretskii
2023-08-26  7:32           ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-09-02  7:30             ` Eli Zaretskii
2023-09-03 17:06               ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-09-03 17:29                 ` Eli Zaretskii
2023-09-03 17:52                 ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-09-03 19:03                   ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-09-03 19:04                     ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-09-04 10:53                   ` Eli Zaretskii
2023-09-04 15:54                     ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-09-04 15:59                       ` Eli Zaretskii
2023-09-03 17:22               ` Juri Linkov
2023-09-03 17:44                 ` Eli Zaretskii

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.