[doc, code] Emacs Lisp Intro: Writing Defuns.