[slime-devel] [rant] Re: smarter loop indentation?

Madhu enometh at meer.net
Sat Apr 21 02:47:33 UTC 2007


* Nikodemus Siivola <46286F05.2060900 at random-state.net> :
|
| Seriously, though: I _strongly_ recommend you stick with standard
| indentation:

Emacs does not get a lot of lisp indentation right including some
basic patterns.  No point calling what a particular version of emacs
does "the standard".

- M-C-q (indent-sexp) and M-x indent-region indent the same code
  differently. whitespaces appear at different parts.

- docstrings are filled according to emacs-lisp-docstring-fill-column

- prog should be indented with lisp-indent-tagbody. It isn't.

- loop indentation fails for patterns that the developer did not try
  and fix.

- But even basic indentation is weird. As examples: LET and WITH-SLOTS:

(let (foobarcar var
                (bar nil))
    ...)


Instead of

(let (foobarcar var
      (bar nil))
    ,,,)

Which would be consistent with:

(let (foobarcar
      (bar nil))
  ...)


- Problems with macro calls: Same problem as the basic indentation.

(with-open-file (foo "0123456789010123456789" :element-type '(unsigned-byte 8)
                     :if-exists :supersede)
  ,,,)

(with-open-file (foo3456789010123456789 "foo" :element-type '(unsigned-byte 8)
	  	                          :if-exists :supersede)
  ,,,)

^^ Why should the second line be indented any differently from the
first example?

This is actually a case for "less uniform" via the "standard"


- Similar problem with function calls| leading to problems formatting
  code within some given fill-column-width.

etc.

--
Madhu




More information about the slime-devel mailing list