]> code.delx.au - gnu-emacs/blobdiff - src/intervals.c
Addendum to: Undo in region after markers in undo history relocated
[gnu-emacs] / src / intervals.c
index 0e3b684f570d7badb5bc514109d5e2f21bf76ce0..703c0cefbd50c9f01eaa7f4ed28dfbf4392e194a 100644 (file)
@@ -1,5 +1,5 @@
 /* Code for doing intervals.
-   Copyright (C) 1993-1995, 1997-1998, 2001-2013 Free Software
+   Copyright (C) 1993-1995, 1997-1998, 2001-2014 Free Software
    Foundation, Inc.
 
 This file is part of GNU Emacs.
@@ -60,16 +60,7 @@ static INTERVAL reproduce_tree (INTERVAL, INTERVAL);
 \f
 /* Utility functions for intervals.  */
 
-/* Use these functions to set Lisp_Object
-   or pointer slots of struct interval.  */
-
-static void
-set_interval_object (INTERVAL i, Lisp_Object obj)
-{
-  eassert (BUFFERP (obj) || STRINGP (obj));
-  i->up_obj = 1;
-  i->up.obj = obj;
-}
+/* Use these functions to set pointer slots of struct interval.  */
 
 static void
 set_interval_left (INTERVAL i, INTERVAL left)
@@ -676,6 +667,7 @@ find_interval (register INTERVAL tree, register ptrdiff_t position)
 
   while (1)
     {
+      eassert (tree);
       if (relative_position < LEFT_TOTAL_LENGTH (tree))
        {
          tree = tree->left;