# HG changeset patch # User Richard M. Stallman # Date 774489190 0 # Node ID e8556db1b7f3e138392a897e77b12cb622a82820 # Parent 1a0af0f4fb1d419dde03122a10ee76e3d9083e03 (Fget_text_property): Simplify using Ftext_properties_at. diff -r 1a0af0f4fb1d -r e8556db1b7f3 src/textprop.c --- a/src/textprop.c Sun Jul 17 16:50:41 1994 +0000 +++ b/src/textprop.c Sun Jul 17 23:53:10 1994 +0000 @@ -501,25 +501,9 @@ If POSITION is at the end of OBJECT, the value is nil.") (pos, prop, object) Lisp_Object pos, object; - register Lisp_Object prop; + Lisp_Object prop; { - register INTERVAL i; - register Lisp_Object tail; - - if (NILP (object)) - XSET (object, Lisp_Buffer, current_buffer); - i = validate_interval_range (object, &pos, &pos, soft); - if (NULL_INTERVAL_P (i)) - return Qnil; - - /* If POS is at the end of the interval, - it means it's the end of OBJECT. - There are no properties at the very end, - since no character follows. */ - if (XINT (pos) == LENGTH (i) + i->position) - return Qnil; - - return textget (i->plist, prop); + return textget (Ftext_properties_at (pos, object), prop); } DEFUN ("get-char-property", Fget_char_property, Sget_char_property, 2, 3, 0,