> This was fallout from 9b980e269, aka bug #28412, where now we prompt for
> buffers that have functions in the `write-contents-functions' hook.
Ah, I see I was looking at the wrong version of the code, sorry.
So the question becomes: why does " *Code-Fontify*" have a non-nil
write-contents-functions?
Looking at ggtags.el, I also wonder why the buffer survives the call to
ggtags-fontify-code. I would have expected ggtags-fontify-code to look
more like:
(cl-defun ggtags-fontify-code (code &optional (mode major-mode))
(cl-check-type mode function)
(cl-typecase code ;; FIXME: Using `stringp` is more efficient.
((not string) code)
(string
(with-temp-buffer
(insert code)
;; FIXME: `delay-mode-hooks' needs a comment
(delay-mode-hooks (funcall mode))
(font-lock-ensure)
(buffer-string)))))
Kaushal Modi