[slime-devel] slime-beginning-of-defun doesn't push point

Mark H. David mhd at yv.org
Thu Mar 3 19:49:24 UTC 2011

One correction to my original post: the key sequence should be C-u 
C-space (not C-u M-space) to go back to where you were before doing C-M-a.

On 3/3/2011 2:45 PM, Mark H. David wrote:
> I created the following revised definition for
> slime-beginning-of-defun in
> slime/contrib/slime-editing-commands.el, adding (push-mark)
> before the basic body.
> (defun slime-beginning-of-defun ()
>   (interactive)
>   (push-mark)
>   (if (and (boundp 'slime-repl-input-start-mark)
>            slime-repl-input-start-mark)
>       (slime-repl-beginning-of-defun)
>       (beginning-of-defun)))
> It works. Thanks!
> -Mark
> On 3/3/2011 2:15 AM, Helmut Eller wrote:
>> * Mark H. David [2011-03-02 21:32] writes:
>>> When you do C-M-A (slime-beginning-of-defun), and then do C-u M-space,
Should be C-u C-space
>>> it's supposed to take you back where you started. This doesn't seem to
>>> work now.  I'm not sure when this got broken, or why, or if it's an
>>> intentional "improvement", and I don't have time to track it down.  If
>>> anyone knows what's going on with that, I'd appreciate knowing.  I 
>>> think
>>> it should be fixed for everyone, but I'd settle for a private patch.
>>> Thanks!
>> I wasn't even aware that C-M-a pushes the mark.  C-M-a is bound to
>> slime-beginning-of-defun in contrib/slime-editing-commands.el.  If you
>> don't load that contrib you get the plain beginning-of-defun that pushes
>> the mark.
>> The problem seems to be that slime-beginning-of-defun calls
>> beginning-of-defun as subroutine but beginning-of-defun only pushes the
>> mark after inspecting the this-command variable to see if the command is
>> called beginning-of-defun.  Maybe using call-interactively would help.
>> Helmut
>> _______________________________________________
>> slime-devel site list
>> slime-devel at common-lisp.net
>> http://common-lisp.net/mailman/listinfo/slime-devel

More information about the slime-devel mailing list