summaryrefslogtreecommitdiff
path: root/src/textprop.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/textprop.c')
-rw-r--r--src/textprop.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/textprop.c b/src/textprop.c
index cc364d5a38c..03b8de120cd 100644
--- a/src/textprop.c
+++ b/src/textprop.c
@@ -98,6 +98,14 @@ modify_region (Lisp_Object buffer, Lisp_Object start, Lisp_Object end)
set_buffer_internal (old);
}
+/* Complain if object is not string or buffer type. */
+
+static void
+CHECK_STRING_OR_BUFFER (Lisp_Object x)
+{
+ CHECK_TYPE (STRINGP (x) || BUFFERP (x), Qbuffer_or_string_p, x);
+}
+
/* Extract the interval at the position pointed to by BEGIN from
OBJECT, a string or buffer. Additionally, check that the positions
pointed to by BEGIN and END are within the bounds of OBJECT, and