See question number two in the faq: http://www.cons.org/cmucl/FAQ.html
And yes, while your example does work the way you want in sbcl (because a isn't special) you should have noticed that for both the setf and the defun g that sbcl warned you "a" was undefined. If you defvar or defparameter instead of setf then sbcl gives the same answer as cmucl.
