| 1 | Fix 'scheme-indent-function' to indent s-expressions starting with a keyword
|
| 2 | properly, like this:
|
| 3 |
|
| 4 | (#:foo 1
|
| 5 | #:bar 2)
|
| 6 |
|
| 7 | instead of like this:
|
| 8 |
|
| 9 | (#:foo 1
|
| 10 | #:bar 2)
|
| 11 |
|
| 12 | The fix is made by Mark H Weaver <[email protected]>:
|
| 13 | <http://www.netris.org/~mhw/scheme-indent-function.el>
|
| 14 |
|
| 15 | |
| 16 | |
| 17 | @@ -494,6 +494,12 @@ indentation."
|
| 18 | (> (length function) 3)
|
| 19 | (string-match "\\`def" function)))
|
| 20 | (lisp-indent-defform state indent-point))
|
| 21 | + ((and (null method)
|
| 22 | + (> (length function) 1)
|
| 23 | + ;; The '#' in '#:' seems to get lost, not sure why
|
| 24 | + (string-match "\\`:" function))
|
| 25 | + (let ((lisp-body-indent 1))
|
| 26 | + (lisp-indent-defform state indent-point)))
|
| 27 | ((integerp method)
|
| 28 | (lisp-indent-specform method state
|
| 29 | indent-point normal-indent))
|