# HG changeset patch # User Kenichi Handa # Date 1029378470 0 # Node ID d50b0a9ea97a41478ecf3518948a4cbe0fc52ef6 # Parent 28fee7bb4dabc6c635d429f4481a8ea73d8879c7 (fontset_add): Make the type `int'. (fontset_id_valid_p): Define it if FONTSET_DEBUG is defined. diff -r 28fee7bb4dab -r d50b0a9ea97a src/fontset.c --- a/src/fontset.c Thu Aug 15 02:27:11 2002 +0000 +++ b/src/fontset.c Thu Aug 15 02:27:50 2002 +0000 @@ -229,13 +229,28 @@ /* Prototype declarations for static functions. */ +static int fontset_add P_ ((Lisp_Object, Lisp_Object, Lisp_Object, + Lisp_Object)); static Lisp_Object make_fontset P_ ((Lisp_Object, Lisp_Object, Lisp_Object)); -static int fontset_id_valid_p P_ ((int)); static Lisp_Object fontset_pattern_regexp P_ ((Lisp_Object)); static void accumulate_script_ranges P_ ((Lisp_Object, Lisp_Object, Lisp_Object)); static Lisp_Object find_font_encoding P_ ((char *)); +#ifdef FONTSET_DEBUG + +/* Return 1 if ID is a valid fontset id, else return 0. */ + +static int +fontset_id_valid_p (id) + int id; +{ + return (id >= 0 && id < ASIZE (Vfontset_table) - 1); +} + +#endif + + /********** MACROS AND FUNCTIONS TO HANDLE FONTSET **********/ @@ -340,7 +355,7 @@ Fmake_vector (make_number (1), (elt))) \ : fontset_add ((fontset), (range), (elt), (add))) -static void +static int fontset_add (fontset, range, elt, add) Lisp_Object fontset, range, elt, add; { @@ -368,6 +383,7 @@ char_table_set_range (fontset, from, to1, elt1); from = to1 + 1; } while (from < to); + return 0; }