unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* before-save-hook not run by 'compile'?
@ 2018-01-02 13:53 Stephen Leake
  2018-01-05 14:21 ` Eli Zaretskii
  0 siblings, 1 reply; 2+ messages in thread
From: Stephen Leake @ 2018-01-02 13:53 UTC (permalink / raw)
  To: emacs-devel

I have 'delete-trailing-whitespace' in 'before-save-hook'; the Ada
compiler I'm using complains if there is trailing whitespace.

However, sometimes when I edit a file and then invoke 'compile', the
file is save, but 'delete-trailing-whitespace' is _not_ run.

If I invoke 'save-some-buffers' directly, 'delete-trailing-whitespace'
is run.

I'm running emacs-26, built from the branch.

I've looked thru the code for compile, and it appears to call
'save-buffer', which appears to run the hook.

I've tried to instrument save-buffer for edebug, but then running
'compile' crashes emacs (with no helpful messages).

Can anyone shed any light on this?

-- 
-- Stephe



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

end of thread, other threads:[~2018-01-05 14:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-01-02 13:53 before-save-hook not run by 'compile'? Stephen Leake
2018-01-05 14:21 ` Eli Zaretskii

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