]> git.eshelyaron.com Git - emacs.git/commitdiff
Update comments.
authorChong Yidong <cyd@stupidchicken.com>
Tue, 23 May 2006 00:49:55 +0000 (00:49 +0000)
committerChong Yidong <cyd@stupidchicken.com>
Tue, 23 May 2006 00:49:55 +0000 (00:49 +0000)
lisp/simple.el
src/intervals.c

index cee04f4a961b017c855b5652b5e7eb97f62e3c7d..2209603d91ccd23ec994a64133af0ca716c3f1e4 100644 (file)
@@ -3645,10 +3645,14 @@ Outline mode sets this."
        (setq new (point))
 
        ;; Process intangibility within a line.
-       ;; Move to the chosen destination position from above,
-       ;; with intangibility processing enabled.
-
-       ;; Avoid calling point-entered and point-left.
+       ;; With inhibit-point-motion-hooks bound to nil, a call to
+       ;; goto-char moves point past intangible text.
+
+       ;; However, inhibit-point-motion-hooks controls both the
+       ;; intangibility and the point-entered/point-left hooks.  The
+       ;; following hack avoids calling the point-* hooks
+       ;; unnecessarily.  Note that we move *forward* past intangible
+       ;; text when the initial and final points are the same.
        (goto-char new)
        (let ((inhibit-point-motion-hooks nil))
          (goto-char new)
index e69ff701387d500eeb08970dcb1319a2bdd30cc8..20c4c191a9319d4444f56af728c97b288f0db61a 100644 (file)
@@ -2016,6 +2016,10 @@ set_point_both (buffer, charpos, bytepos)
   register INTERVAL to, from, toprev, fromprev;
   int buffer_point;
   int old_position = BUF_PT (buffer);
+  /* This ensures that we move forward past intangible text when the
+     initial position is the same as the destination, in the rare
+     instances where this is important, e.g. in line-move-finish
+     (simple.el).  */
   int backwards = (charpos < old_position ? 1 : 0);
   int have_overlays;
   int original_position;