emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/calc/calc-yank.el,v


From: Jay Belanger
Subject: [Emacs-diffs] Changes to emacs/lisp/calc/calc-yank.el,v
Date: Sun, 18 May 2008 05:09:10 +0000

CVSROOT:        /cvsroot/emacs
Module name:    emacs
Changes by:     Jay Belanger <jpb>      08/05/18 05:09:10

Index: calc-yank.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/calc/calc-yank.el,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -b -r1.29 -r1.30
--- calc-yank.el        6 May 2008 03:15:56 -0000       1.29
+++ calc-yank.el        18 May 2008 05:09:10 -0000      1.30
@@ -46,6 +46,7 @@
                   (setq num (1- num)))
               (setq num (- num n)
                     n (- n))))
+         (calc-check-stack num)
         (let ((stuff (calc-top-list n (- num n -1))))
           (calc-cursor-stack-index num)
           (let ((first (point)))
@@ -82,9 +83,15 @@
        (calc-force-refresh)
        (calc-set-command-flag 'no-align)
        (let* ((top-num (calc-locate-cursor-element top))
+              (top-pos (save-excursion
+                         (calc-cursor-stack-index top-num)
+                         (point)))
              (bot-num (calc-locate-cursor-element (1- bot)))
+              (bot-pos (save-excursion
+                         (calc-cursor-stack-index (max 0 (1- bot-num)))
+                         (point)))
              (num (- top-num bot-num -1)))
-        (copy-region-as-kill top bot)
+        (copy-region-as-kill top-pos bot-pos)
         (setq calc-last-kill (cons (car kill-ring)
                                    (calc-top-list num bot-num)))
         (if (not no-delete)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]