diff options
| author | Miles Bader | 2009-02-04 05:48:16 +0000 |
|---|---|---|
| committer | Miles Bader | 2009-02-04 05:48:16 +0000 |
| commit | 61eee794dba0de5906d8b0aef30cc98e634b3b2d (patch) | |
| tree | ff2b933a1ba902ae1096e394bac3069bc31e8ecd | |
| parent | aacd8ba187331ffba520da1b55d0bd2e15f3aba4 (diff) | |
| download | emacs-61eee794dba0de5906d8b0aef30cc98e634b3b2d.tar.gz emacs-61eee794dba0de5906d8b0aef30cc98e634b3b2d.zip | |
Add "^" to interactive spec of sexp movement commands
Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1534
| -rw-r--r-- | lisp/ChangeLog | 6 | ||||
| -rw-r--r-- | lisp/emacs-lisp/lisp.el | 20 |
2 files changed, 16 insertions, 10 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 11d748f5862..9c806c616b9 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,9 @@ | |||
| 1 | 2009-02-04 Miles Bader <miles@gnu.org> | ||
| 2 | |||
| 3 | * emacs-lisp/lisp.el (forward-sexp, backward-sexp, forward-list) | ||
| 4 | (backward-list, backward-up-list, beginning-of-defun) | ||
| 5 | (beginning-of-defun-raw, end-of-defun): Add "^" to interactive spec. | ||
| 6 | |||
| 1 | 2009-02-04 Glenn Morris <rgm@gnu.org> | 7 | 2009-02-04 Glenn Morris <rgm@gnu.org> |
| 2 | 8 | ||
| 3 | * mail/mail-utils.el (mail-fetch-field): Previous doc fix was | 9 | * mail/mail-utils.el (mail-fetch-field): Previous doc fix was |
diff --git a/lisp/emacs-lisp/lisp.el b/lisp/emacs-lisp/lisp.el index 76141c56274..ba1546980ae 100644 --- a/lisp/emacs-lisp/lisp.el +++ b/lisp/emacs-lisp/lisp.el | |||
| @@ -53,7 +53,7 @@ Should take the same arguments and behave similarly to `forward-sexp'.") | |||
| 53 | With ARG, do it that many times. Negative arg -N means | 53 | With ARG, do it that many times. Negative arg -N means |
| 54 | move backward across N balanced expressions. | 54 | move backward across N balanced expressions. |
| 55 | This command assumes point is not in a string or comment." | 55 | This command assumes point is not in a string or comment." |
| 56 | (interactive "p") | 56 | (interactive "^p") |
| 57 | (or arg (setq arg 1)) | 57 | (or arg (setq arg 1)) |
| 58 | (if forward-sexp-function | 58 | (if forward-sexp-function |
| 59 | (funcall forward-sexp-function arg) | 59 | (funcall forward-sexp-function arg) |
| @@ -65,7 +65,7 @@ This command assumes point is not in a string or comment." | |||
| 65 | With ARG, do it that many times. Negative arg -N means | 65 | With ARG, do it that many times. Negative arg -N means |
| 66 | move forward across N balanced expressions. | 66 | move forward across N balanced expressions. |
| 67 | This command assumes point is not in a string or comment." | 67 | This command assumes point is not in a string or comment." |
| 68 | (interactive "p") | 68 | (interactive "^p") |
| 69 | (or arg (setq arg 1)) | 69 | (or arg (setq arg 1)) |
| 70 | (forward-sexp (- arg))) | 70 | (forward-sexp (- arg))) |
| 71 | 71 | ||
| @@ -100,7 +100,7 @@ This command assumes point is not in a string or comment." | |||
| 100 | With ARG, do it that many times. | 100 | With ARG, do it that many times. |
| 101 | Negative arg -N means move backward across N groups of parentheses. | 101 | Negative arg -N means move backward across N groups of parentheses. |
| 102 | This command assumes point is not in a string or comment." | 102 | This command assumes point is not in a string or comment." |
| 103 | (interactive "p") | 103 | (interactive "^p") |
| 104 | (or arg (setq arg 1)) | 104 | (or arg (setq arg 1)) |
| 105 | (goto-char (or (scan-lists (point) arg 0) (buffer-end arg)))) | 105 | (goto-char (or (scan-lists (point) arg 0) (buffer-end arg)))) |
| 106 | 106 | ||
| @@ -109,7 +109,7 @@ This command assumes point is not in a string or comment." | |||
| 109 | With ARG, do it that many times. | 109 | With ARG, do it that many times. |
| 110 | Negative arg -N means move forward across N groups of parentheses. | 110 | Negative arg -N means move forward across N groups of parentheses. |
| 111 | This command assumes point is not in a string or comment." | 111 | This command assumes point is not in a string or comment." |
| 112 | (interactive "p") | 112 | (interactive "^p") |
| 113 | (or arg (setq arg 1)) | 113 | (or arg (setq arg 1)) |
| 114 | (forward-list (- arg))) | 114 | (forward-list (- arg))) |
| 115 | 115 | ||
| @@ -118,7 +118,7 @@ This command assumes point is not in a string or comment." | |||
| 118 | With ARG, do this that many times. | 118 | With ARG, do this that many times. |
| 119 | A negative argument means move backward but still go down a level. | 119 | A negative argument means move backward but still go down a level. |
| 120 | This command assumes point is not in a string or comment." | 120 | This command assumes point is not in a string or comment." |
| 121 | (interactive "p") | 121 | (interactive "^p") |
| 122 | (or arg (setq arg 1)) | 122 | (or arg (setq arg 1)) |
| 123 | (let ((inc (if (> arg 0) 1 -1))) | 123 | (let ((inc (if (> arg 0) 1 -1))) |
| 124 | (while (/= arg 0) | 124 | (while (/= arg 0) |
| @@ -130,7 +130,7 @@ This command assumes point is not in a string or comment." | |||
| 130 | With ARG, do this that many times. | 130 | With ARG, do this that many times. |
| 131 | A negative argument means move forward but still to a less deep spot. | 131 | A negative argument means move forward but still to a less deep spot. |
| 132 | This command assumes point is not in a string or comment." | 132 | This command assumes point is not in a string or comment." |
| 133 | (interactive "p") | 133 | (interactive "^p") |
| 134 | (up-list (- (or arg 1)))) | 134 | (up-list (- (or arg 1)))) |
| 135 | 135 | ||
| 136 | (defun up-list (&optional arg) | 136 | (defun up-list (&optional arg) |
| @@ -138,7 +138,7 @@ This command assumes point is not in a string or comment." | |||
| 138 | With ARG, do this that many times. | 138 | With ARG, do this that many times. |
| 139 | A negative argument means move backward but still to a less deep spot. | 139 | A negative argument means move backward but still to a less deep spot. |
| 140 | This command assumes point is not in a string or comment." | 140 | This command assumes point is not in a string or comment." |
| 141 | (interactive "p") | 141 | (interactive "^p") |
| 142 | (or arg (setq arg 1)) | 142 | (or arg (setq arg 1)) |
| 143 | (let ((inc (if (> arg 0) 1 -1))) | 143 | (let ((inc (if (> arg 0) 1 -1))) |
| 144 | (while (/= arg 0) | 144 | (while (/= arg 0) |
| @@ -213,7 +213,7 @@ defun's beginning. | |||
| 213 | Regardless of the values of `defun-prompt-regexp' and | 213 | Regardless of the values of `defun-prompt-regexp' and |
| 214 | `beginning-of-defun-function', point always moves to the | 214 | `beginning-of-defun-function', point always moves to the |
| 215 | beginning of the line whenever the search is successful." | 215 | beginning of the line whenever the search is successful." |
| 216 | (interactive "p") | 216 | (interactive "^p") |
| 217 | (or (not (eq this-command 'beginning-of-defun)) | 217 | (or (not (eq this-command 'beginning-of-defun)) |
| 218 | (eq last-command 'beginning-of-defun) | 218 | (eq last-command 'beginning-of-defun) |
| 219 | (and transient-mark-mode mark-active) | 219 | (and transient-mark-mode mark-active) |
| @@ -229,7 +229,7 @@ is non-nil. | |||
| 229 | 229 | ||
| 230 | If variable `beginning-of-defun-function' is non-nil, its value | 230 | If variable `beginning-of-defun-function' is non-nil, its value |
| 231 | is called as a function to find the defun's beginning." | 231 | is called as a function to find the defun's beginning." |
| 232 | (interactive "p") ; change this to "P", maybe, if we ever come to pass ARG | 232 | (interactive "^p") ; change this to "P", maybe, if we ever come to pass ARG |
| 233 | ; to beginning-of-defun-function. | 233 | ; to beginning-of-defun-function. |
| 234 | (unless arg (setq arg 1)) | 234 | (unless arg (setq arg 1)) |
| 235 | (cond | 235 | (cond |
| @@ -335,7 +335,7 @@ matches the open-parenthesis that starts a defun; see function | |||
| 335 | 335 | ||
| 336 | If variable `end-of-defun-function' is non-nil, its value | 336 | If variable `end-of-defun-function' is non-nil, its value |
| 337 | is called as a function to find the defun's end." | 337 | is called as a function to find the defun's end." |
| 338 | (interactive "p") | 338 | (interactive "^p") |
| 339 | (or (not (eq this-command 'end-of-defun)) | 339 | (or (not (eq this-command 'end-of-defun)) |
| 340 | (eq last-command 'end-of-defun) | 340 | (eq last-command 'end-of-defun) |
| 341 | (and transient-mark-mode mark-active) | 341 | (and transient-mark-mode mark-active) |