diff options
| author | Stefan Monnier | 2014-05-10 23:48:15 -0400 |
|---|---|---|
| committer | Stefan Monnier | 2014-05-10 23:48:15 -0400 |
| commit | 4eb436826bd7912925634624beaf4173546dad49 (patch) | |
| tree | 54937e814b6e9235f823bfee41c187a901b9a988 | |
| parent | 0994e45d163f121a64084a3b8bf7bb67dc4cef18 (diff) | |
| download | emacs-4eb436826bd7912925634624beaf4173546dad49.tar.gz emacs-4eb436826bd7912925634624beaf4173546dad49.zip | |
* lisp/emacs-lisp/lisp-mode.el (preceding-sexp): Exclude leading "," which
are a hindrance for C-x C-e.
| -rw-r--r-- | lisp/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/emacs-lisp/lisp-mode.el | 26 |
2 files changed, 15 insertions, 16 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b7a0f49bded..a44ba6dc000 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2014-05-11 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | |||
| 3 | * emacs-lisp/lisp-mode.el (preceding-sexp): Exclude leading "," which | ||
| 4 | are a hindrance for C-x C-e. | ||
| 5 | |||
| 1 | 2014-05-11 Leo Liu <sdl.web@gmail.com> | 6 | 2014-05-11 Leo Liu <sdl.web@gmail.com> |
| 2 | 7 | ||
| 3 | * net/rcirc.el (rcirc-sentinel): Fix last change. | 8 | * net/rcirc.el (rcirc-sentinel): Fix last change. |
diff --git a/lisp/emacs-lisp/lisp-mode.el b/lisp/emacs-lisp/lisp-mode.el index 690aa3d7460..21529894fed 100644 --- a/lisp/emacs-lisp/lisp-mode.el +++ b/lisp/emacs-lisp/lisp-mode.el | |||
| @@ -1017,26 +1017,20 @@ If CHAR is not a character, return nil." | |||
| 1017 | (forward-sexp -1)))) | 1017 | (forward-sexp -1)))) |
| 1018 | 1018 | ||
| 1019 | (save-restriction | 1019 | (save-restriction |
| 1020 | ;; vladimir@cs.ualberta.ca 30-Jul-1997: skip ` in | 1020 | (if (and ignore-quotes (eq (following-char) ?`)) |
| 1021 | ;; `variable' so that the value is returned, not the | 1021 | ;; vladimir@cs.ualberta.ca 30-Jul-1997: Skip ` in `variable' so |
| 1022 | ;; name | 1022 | ;; that the value is returned, not the name. |
| 1023 | (if (and ignore-quotes | ||
| 1024 | (eq (following-char) ?`)) | ||
| 1025 | (forward-char)) | 1023 | (forward-char)) |
| 1024 | (when (looking-at ",@?") (goto-char (match-end 0))) | ||
| 1026 | (narrow-to-region (point-min) opoint) | 1025 | (narrow-to-region (point-min) opoint) |
| 1027 | (setq expr (read (current-buffer))) | 1026 | (setq expr (read (current-buffer))) |
| 1028 | ;; If it's an (interactive ...) form, it's more | 1027 | ;; If it's an (interactive ...) form, it's more useful to show how an |
| 1029 | ;; useful to show how an interactive call would | 1028 | ;; interactive call would use it. |
| 1030 | ;; use it. | 1029 | ;; FIXME: Is it really the right place for this? |
| 1031 | (and (consp expr) | 1030 | (when (eq (car-safe expr) 'interactive) |
| 1032 | (eq (car expr) 'interactive) | ||
| 1033 | (setq expr | 1031 | (setq expr |
| 1034 | (list 'call-interactively | 1032 | `(call-interactively |
| 1035 | (list 'quote | 1033 | (lambda (&rest args) ,expr args)))) |
| 1036 | (list 'lambda | ||
| 1037 | '(&rest args) | ||
| 1038 | expr | ||
| 1039 | 'args))))) | ||
| 1040 | expr))))) | 1034 | expr))))) |
| 1041 | 1035 | ||
| 1042 | 1036 | ||