emacs-diffs
[Top][All Lists]
Advanced

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

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


From: Chong Yidong
Subject: [Emacs-diffs] Changes to emacs/lisp/simple.el,v
Date: Sat, 12 Jul 2008 18:33:48 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Chong Yidong <cyd>      08/07/12 18:33:48

Index: simple.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/simple.el,v
retrieving revision 1.932
retrieving revision 1.933
diff -u -b -r1.932 -r1.933
--- simple.el   11 Jul 2008 18:11:06 -0000      1.932
+++ simple.el   12 Jul 2008 18:33:47 -0000      1.933
@@ -3996,18 +3996,17 @@
                (or (memq last-command '(next-line previous-line))
                    ;; In case we're called from some other command.
                    (eq last-command this-command)))
-    (setq temporary-goal-column
-          (/ (car (nth 2 (posn-at-point))) 1.0 (frame-char-width))))
-  (let ((moved (vertical-motion
-               (cons (or goal-column
-                         (truncate temporary-goal-column))
-                     arg))))
-    (or (= arg moved)
+    (let ((x (car (nth 2 (posn-at-point)))))
+      (when x
+       (setq temporary-goal-column (/ (float x) (frame-char-width))))))
+  (or (= (vertical-motion
+         (cons (or goal-column (truncate temporary-goal-column)) arg))
+        arg)
        (unless noerror
          (signal (if (< arg 0)
                      'beginning-of-buffer
                    'end-of-buffer)
-                 nil)))))
+               nil))))
 
 ;; This is the guts of next-line and previous-line.
 ;; Arg says how many lines to move.




reply via email to

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