Is it possible to change how slime (is slime controlling the ident process??) indents let forms?
I prefer a let to look like this:
(let (var1 var2 var3 var4 var5 var6) ...)
but its currently indented like this:
(let (var1 var2 var3 var4 var5 var6) ...)
Can I change this? Or is slime the wrong place to look?
Thanks for any info. -Ram
ramb@sonic.net writes:
Is it possible to change how slime (is slime controlling the ident process??) indents let forms?
The lisp-indent-function does the indentation and SLIME is not quite responsible for the indentation (or syntax highlighting). SLIME gives the indentation code some hints about macros with &body arguments, but only if there isn't already some other rule.
The idea is that SLIME does only the stuff which needs interaction with the external Lisp process.
I prefer a let to look like this:
(let (var1 var2 var3 var4 var5 var6) ...)
but its currently indented like this:
(let (var1 var2 var3 var4 var5 var6) ...)
Can I change this? Or is slime the wrong place to look?
If your lisp-indent-function is set to common-lisp-indent-function you could try something like:
(put 'let 'common-lisp-indent-function '(&lambda &body))
If you use another indent-function you may need other parameters. For very complicated syntax, like loop, you may also specify your own function like:
(put 'let 'common-lisp-indent-function 'my-indent-fun)
Helmut.
Helmut Eller heller@common-lisp.net writes:
For very complicated syntax, like loop, you may also specify your own function like:
(put 'let 'common-lisp-indent-function 'my-indent-fun)
Anybody with a good[*] LOOP indentation function?
Paolo
[*] I.e. better than the default one that comes with lisp-mode/cl-indent.el.
Paolo Amoroso wrote:
Helmut Eller heller@common-lisp.net writes:
For very complicated syntax, like loop, you may also specify your own function like:
(put 'let 'common-lisp-indent-function 'my-indent-fun)
Anybody with a good[*] LOOP indentation function?
I posted one in this group a few months ago.
Paolo
[*] I.e. better than the default one that comes with lisp-mode/cl-indent.el.
If your lisp-indent-function is set to common-lisp-indent-function you could try something like:
(put 'let 'common-lisp-indent-function '(&lambda &body))
If you use another indent-function you may need other parameters. For very complicated syntax, like loop, you may also specify your own function like:
(put 'let 'common-lisp-indent-function 'my-indent-fun)
Thank you! This did the trick.
For those who use xemacs you will need to grab cl-indent.el from a recent GNU emacs release and use that instead of the rather old version from xemacs...
-Ram