diff options
Diffstat (limited to 'lisp/emacs-lisp/cl-indent.el')
-rw-r--r-- | lisp/emacs-lisp/cl-indent.el | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/lisp/emacs-lisp/cl-indent.el b/lisp/emacs-lisp/cl-indent.el index 40434636e62..01bdfbf4bf2 100644 --- a/lisp/emacs-lisp/cl-indent.el +++ b/lisp/emacs-lisp/cl-indent.el @@ -1,6 +1,6 @@ ;;; cl-indent.el --- enhanced lisp-indent mode -;; Copyright (C) 1987, 2000-2011 Free Software Foundation, Inc. +;; Copyright (C) 1987, 2000-2012 Free Software Foundation, Inc. ;; Author: Richard Mlynarik <mly@eddie.mit.edu> ;; Created: July 1987 @@ -104,6 +104,7 @@ If non-nil, alignment is done with the first keyword \(defun foo (arg1 arg2 &rest rest &key key1 key2) #|...|#)" + :version "24.1" :type 'boolean :group 'lisp-indent) @@ -111,6 +112,7 @@ If non-nil, alignment is done with the first keyword "Indentation of lambda list keyword parameters. See `lisp-lambda-list-keyword-parameter-alignment' for more information." + :version "24.1" :type 'integer :group 'lisp-indent) @@ -130,6 +132,7 @@ If non-nil, alignment is done with the first parameter \(defun foo (arg1 arg2 &key key1 key2 key3 key4) #|...|#)" + :version "24.1" :type 'boolean :group 'lisp-indent) @@ -159,14 +162,19 @@ is set to `defun'.") (current-column)))) (goto-char indent-point) (beginning-of-line) - (cond ((not (extended-loop-p (elt state 1))) - (+ loop-indentation lisp-simple-loop-indentation)) - ((looking-at "^\\s-*\\(:?\\sw+\\|;\\)") - (+ loop-indentation lisp-loop-keyword-indentation)) - (t - (+ loop-indentation lisp-loop-forms-indentation))))) - - + (list + (cond ((not (extended-loop-p (elt state 1))) + (+ loop-indentation lisp-simple-loop-indentation)) + ((looking-at "^\\s-*\\(:?\\sw+\\|;\\)") + (+ loop-indentation lisp-loop-keyword-indentation)) + (t + (+ loop-indentation lisp-loop-forms-indentation))) + ;; Tell the caller that the next line needs recomputation, even + ;; though it doesn't start a sexp. + loop-indentation))) + + +;; Cf (info "(elisp)Specification List") ;;;###autoload (defun common-lisp-indent-function (indent-point state) "Function to indent the arguments of a Lisp function call. |