Mercurial > emacs
changeset 70423:b021bec005d5
(xscheme-insert-expression): Use add-to-history.
author | Kim F. Storm <storm@cua.dk> |
---|---|
date | Fri, 05 May 2006 23:38:58 +0000 |
parents | 84417eaa098c |
children | bb09ca6ec650 |
files | lisp/progmodes/xscheme.el |
diffstat | 1 files changed, 3 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/progmodes/xscheme.el Fri May 05 23:38:31 2006 +0000 +++ b/lisp/progmodes/xscheme.el Fri May 05 23:38:58 2006 +0000 @@ -580,12 +580,9 @@ ;;;; Scheme expressions ring (defun xscheme-insert-expression (string) - (setq xscheme-expressions-ring (cons string xscheme-expressions-ring)) - (if (> (length xscheme-expressions-ring) xscheme-expressions-ring-max) - (setcdr (nthcdr (1- xscheme-expressions-ring-max) - xscheme-expressions-ring) - nil)) - (setq xscheme-expressions-ring-yank-pointer xscheme-expressions-ring)) + (setq xscheme-expressions-ring-yank-pointer + (add-to-history 'xscheme-expressions-ring string + xscheme-expressions-ring-max))) (defun xscheme-rotate-yank-pointer (arg) "Rotate the yanking point in the kill ring."