aboutsummaryrefslogtreecommitdiffstats
path: root/src/coding.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/coding.c')
-rw-r--r--src/coding.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/coding.c b/src/coding.c
index 42fd81b6322..497c26d4856 100644
--- a/src/coding.c
+++ b/src/coding.c
@@ -655,6 +655,22 @@ static struct coding_system coding_categories[coding_category_max];
655 (charset_list) = CODING_ATTR_CHARSET_LIST (attrs); \ 655 (charset_list) = CODING_ATTR_CHARSET_LIST (attrs); \
656 } while (0) 656 } while (0)
657 657
658static void
659CHECK_NATNUM_CAR (Lisp_Object x)
660{
661 Lisp_Object tmp = XCAR (x);
662 CHECK_NATNUM (tmp);
663 XSETCAR (x, tmp);
664}
665
666static void
667CHECK_NATNUM_CDR (Lisp_Object x)
668{
669 Lisp_Object tmp = XCDR (x);
670 CHECK_NATNUM (tmp);
671 XSETCDR (x, tmp);
672}
673
658 674
659/* Safely get one byte from the source text pointed by SRC which ends 675/* Safely get one byte from the source text pointed by SRC which ends
660 at SRC_END, and set C to that byte. If there are not enough bytes 676 at SRC_END, and set C to that byte. If there are not enough bytes