Emacs modify quit-window to delete buffer not just bury it

The other answer actually gives slightly incompatible behavior. Consider a situation where you already have a frame split into two windows, then you open a help buffer and quit it. quit-window is smart enough to know that it shouldn't kill the window, just the buffer. It actually even has a few more clever tricks up its sleeve so our best bet is to work with it and just tweak it a bit. Here's a simple way of achieving what you want:

(defadvice quit-window (before quit-window-always-kill)
  "When running `quit-window', always kill the buffer."
  (ad-set-arg 0 t))
(ad-activate 'quit-window)

Just redefining the function seemed to have worked for me ie

(defun quit-window () 
 "modified quit window"
 (interactive)
 (kill-buffer-and-window)
 )

I've never understood the purpose of having a completion or help buffer still available when you are switching buffers after you pressed q to quit it previously.