comparison lisp/=cmulisp.el @ 1368:35a17cd4ae62

(cmulisp-mode): Eliminate compatibility code calling lisp-mode-variables with no arg. (cmulisp-mode-map): Use shared-lisp-mode-map as tail. (cmulisp-args-to-list): Fix typo in recursive call. (cmulisp-buffer): Define variable.
author Richard M. Stallman <rms@gnu.org>
date Thu, 08 Oct 1992 06:44:58 +0000
parents 2619b7a9c11e
children bd3c525fa6fc
comparison
equal deleted inserted replaced
1367:475a8122e0a5 1368:35a17cd4ae62
133 (as in :a, :c, etc.)") 133 (as in :a, :c, etc.)")
134 134
135 (defvar cmulisp-mode-map nil) 135 (defvar cmulisp-mode-map nil)
136 (cond ((not cmulisp-mode-map) 136 (cond ((not cmulisp-mode-map)
137 (setq cmulisp-mode-map 137 (setq cmulisp-mode-map
138 (full-copy-sparse-keymap comint-mode-map)) 138 (nconc (full-copy-sparse-keymap comint-mode-map)
139 (lisp-mode-commands cmulisp-mode-map) 139 shared-lisp-mode-map))
140 (define-key cmulisp-mode-map "\C-x\C-e" 'lisp-eval-last-sexp) 140 (define-key cmulisp-mode-map "\C-x\C-e" 'lisp-eval-last-sexp)
141 (define-key cmulisp-mode-map "\C-c\C-l" 'lisp-load-file) 141 (define-key cmulisp-mode-map "\C-c\C-l" 'lisp-load-file)
142 (define-key cmulisp-mode-map "\C-c\C-k" 'lisp-compile-file) 142 (define-key cmulisp-mode-map "\C-c\C-k" 'lisp-compile-file)
143 (define-key cmulisp-mode-map "\C-c\C-a" 'lisp-show-arglist) 143 (define-key cmulisp-mode-map "\C-c\C-a" 'lisp-show-arglist)
144 (define-key cmulisp-mode-map "\C-c\C-d" 'lisp-describe-sym) 144 (define-key cmulisp-mode-map "\C-c\C-d" 'lisp-describe-sym)
158 (define-key lisp-mode-map "\C-c\C-a" 'lisp-show-arglist) 158 (define-key lisp-mode-map "\C-c\C-a" 'lisp-show-arglist)
159 (define-key lisp-mode-map "\C-c\C-d" 'lisp-describe-sym) 159 (define-key lisp-mode-map "\C-c\C-d" 'lisp-describe-sym)
160 (define-key lisp-mode-map "\C-c\C-f" 'lisp-show-function-documentation) 160 (define-key lisp-mode-map "\C-c\C-f" 'lisp-show-function-documentation)
161 (define-key lisp-mode-map "\C-c\C-v" 'lisp-show-variable-documentation) 161 (define-key lisp-mode-map "\C-c\C-v" 'lisp-show-variable-documentation)
162 162
163 (defvar cmulisp-buffer)
163 164
164 ;;; This function exists for backwards compatibility. 165 ;;; This function exists for backwards compatibility.
165 ;;; Previous versions of this package bound commands to C-c <letter> 166 ;;; Previous versions of this package bound commands to C-c <letter>
166 ;;; bindings, which is not allowed by the gnumacs standard. 167 ;;; bindings, which is not allowed by the gnumacs standard.
167 168
264 (comint-mode) 265 (comint-mode)
265 (setq comint-prompt-regexp inferior-lisp-prompt) 266 (setq comint-prompt-regexp inferior-lisp-prompt)
266 (setq major-mode 'cmulisp-mode) 267 (setq major-mode 'cmulisp-mode)
267 (setq mode-name "CMU Lisp") 268 (setq mode-name "CMU Lisp")
268 (setq mode-line-process '(": %s")) 269 (setq mode-line-process '(": %s"))
269 (if (string-match "^18.4" emacs-version) ; hack. 270 (lisp-mode-variables t)
270 (lisp-mode-variables) ; This is right for 18.49
271 (lisp-mode-variables t)) ; This is right for 18.50
272 (use-local-map cmulisp-mode-map) ;c-c c-k for "kompile" file 271 (use-local-map cmulisp-mode-map) ;c-c c-k for "kompile" file
273 (setq comint-get-old-input (function lisp-get-old-input)) 272 (setq comint-get-old-input (function lisp-get-old-input))
274 (setq comint-input-filter (function lisp-input-filter)) 273 (setq comint-input-filter (function lisp-input-filter))
275 (setq comint-input-sentinel 'ignore) 274 (setq comint-input-sentinel 'ignore)
276 (run-hooks 'cmulisp-mode-hook)) 275 (run-hooks 'cmulisp-mode-hook))
315 (tea-args-to-list (substring string (+ 1 where) 314 (tea-args-to-list (substring string (+ 1 where)
316 (length string))))) 315 (length string)))))
317 (t (let ((pos (string-match "[^ \t]" string))) 316 (t (let ((pos (string-match "[^ \t]" string)))
318 (if (null pos) 317 (if (null pos)
319 nil 318 nil
320 (cmulsip-args-to-list (substring string pos 319 (cmulisp-args-to-list (substring string pos
321 (length string))))))))) 320 (length string)))))))))
322 321
323 (defun lisp-eval-region (start end &optional and-go) 322 (defun lisp-eval-region (start end &optional and-go)
324 "Send the current region to the inferior Lisp process. 323 "Send the current region to the inferior Lisp process.
325 Prefix argument means switch-to-lisp afterwards." 324 Prefix argument means switch-to-lisp afterwards."