buffer-quit-function

buffer-quit-function is a variable defined in `simple.el'.
Its value is
nil

  • This variable may be risky if used as a file-local variable.

Documentation:
Function to call to "quit" the current buffer, or nil if none.
M-ESC ESC calls this function when its more local actions
(such as canceling a prefix argument, minibuffer or region) do not apply.