comparison lisp/modes/lisp-mode.el @ 155:43dd3413c7c7 r20-3b4

Import from CVS: tag r20-3b4
author cvs
date Mon, 13 Aug 2007 09:39:39 +0200
parents 25f70ba0133c
children 28f395d8dc7a
comparison
equal deleted inserted replaced
154:94141801dd7e 155:43dd3413c7c7
364 364
365 ;; XEmacs change 365 ;; XEmacs change
366 (defun eval-interactive (expr) 366 (defun eval-interactive (expr)
367 "Like `eval' except that it transforms defvars to defconsts." 367 "Like `eval' except that it transforms defvars to defconsts."
368 ;; by Stig@hackvan.com 368 ;; by Stig@hackvan.com
369 (if (and (consp expr) 369 (cond ((and (consp expr)
370 (eq (car expr) 'defvar) 370 (eq (car expr) 'defvar)
371 (> (length expr) 2)) 371 (> (length expr) 2))
372 (eval (cons 'defconst (cdr expr))) 372 (eval (cons 'defconst (cdr expr))))
373 (eval expr))) 373 ((and (consp expr)
374 (eq (car expr) 'defcustom)
375 (> (length expr) 2))
376 (makunbound (nth 1 expr))
377 (eval expr))
378 (t
379 (eval expr))))
374 380
375 ;; XEmacs change, based on Bob Weiner suggestion 381 ;; XEmacs change, based on Bob Weiner suggestion
376 (defun eval-last-sexp (eval-last-sexp-arg-internal) ;dynamic scoping wonderment 382 (defun eval-last-sexp (eval-last-sexp-arg-internal) ;dynamic scoping wonderment
377 "Evaluate sexp before point; print value in minibuffer. 383 "Evaluate sexp before point; print value in minibuffer.
378 With argument, print output into current buffer." 384 With argument, print output into current buffer."