Save & load file

edgar edgar-rft at web.de
Wed Jul 15 09:36:50 UTC 2015


Am Tue, 14 Jul 2015 20:15:23 -0500
schrieb Blake McBride <blake at mcbride.name>:

> I had to take the "P" argument out, and then everything worked
> perfectly. Thanks!!
> 
> (I am using GNU Emacs 24.3.1)
> 
> I am surprised this sequence isn't a pre-configured feature of
> standard slime with a keyboard shortcut.  It is my most used sequence.

Maybe because in 2015 most Common Lisp implementations are
compilers and not interpreters anymore?

To me it looks as if you either do unusual things or have
an unusual operating system or Common Lisp implementation,
where both could be a valid explanation.

There's nothing bad in using CL:LOAD, but I can't remember
a situation from the last ten years where I have used it.

- edgar


> On Tue, Jul 14, 2015 at 6:17 PM, edgar <edgar-rft at web.de> wrote:
> 
> > Am Tue, 14 Jul 2015 16:58:31 -0500
> > schrieb Blake McBride <blake at mcbride.name>:
> >
> > > Greetings,
> > >
> > > Long-time lisp user, short time slime user here.  There is
> > > something I like to do frequently but seems to be a real hassle
> > > with slime. I'm sure either there is a command to do what I want,
> > > or it is easy for me to write one.  I thought rather than going
> > > doen an ignorant path, I'd ask the list.  Sure appreciate any
> > > help.
> > >
> > > What I would like is a keyboard command that would:
> > >
> > > 1.  save the current file being edited
> > >
> > > 2.  load (not compile) that file without asking it's name
> >
> > A basic Emacs function doing both could look like this:
> >
> > (defun slime-save-and-load-file ()
> >   (interactive "P")
> >   (let ((filename (buffer-file-name)))
> >     (if (not filename)
> >         (message "Buffer %s is not associated with a file."
> >                  (buffer-name))
> >       (save-buffer)
> >       (slime-load-file filename))))
> >
> > - edgar
> >



-- 
The author of this email does not necessarily endorse the following
advertisements, which are the sole responsibility of the advertiser:




More information about the slime-devel mailing list