diff options
Diffstat (limited to 'src/casetab.c')
-rw-r--r-- | src/casetab.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/casetab.c b/src/casetab.c index 575a48ed146..8778048072c 100644 --- a/src/casetab.c +++ b/src/casetab.c @@ -194,8 +194,7 @@ set_identity (Lisp_Object table, Lisp_Object c, Lisp_Object elt) { if (NATNUMP (elt)) { - int from; - unsigned to; + int from, to; if (CONSP (c)) { @@ -204,7 +203,10 @@ set_identity (Lisp_Object table, Lisp_Object c, Lisp_Object elt) } else from = to = XINT (c); - for (to++; from < to; from++) + + to++; + lint_assume (to <= MAX_CHAR + 1); + for (; from < to; from++) CHAR_TABLE_SET (table, from, make_number (from)); } } @@ -219,8 +221,7 @@ shuffle (Lisp_Object table, Lisp_Object c, Lisp_Object elt) { if (NATNUMP (elt)) { - int from; - unsigned to; + int from, to; if (CONSP (c)) { @@ -230,7 +231,9 @@ shuffle (Lisp_Object table, Lisp_Object c, Lisp_Object elt) else from = to = XINT (c); - for (to++; from < to; from++) + to++; + lint_assume (to <= MAX_CHAR + 1); + for (; from < to; from++) { Lisp_Object tem = Faref (table, elt); Faset (table, elt, make_number (from)); |