Mercurial > emacs
changeset 73049:5fe222b4d692
(optimize_sub_char_table): Don't optimize a sub-char-table
whose default value is non-nil.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Fri, 22 Sep 2006 12:54:38 +0000 |
parents | 4a83c4a89b5e |
children | 9e002a3232ec |
files | src/fns.c |
diffstat | 1 files changed, 6 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/fns.c Fri Sep 22 08:19:55 2006 +0000 +++ b/src/fns.c Fri Sep 22 12:54:38 2006 +0000 @@ -2777,7 +2777,8 @@ else from = 32, to = 128; - if (!SUB_CHAR_TABLE_P (*table)) + if (!SUB_CHAR_TABLE_P (*table) + || ! NILP (XCHAR_TABLE (*table)->defalt)) return; elt = XCHAR_TABLE (*table)->contents[from++]; for (; from < to; from++) @@ -2792,7 +2793,7 @@ Lisp_Object table; { Lisp_Object elt; - int dim; + int dim, chars; int i, j; CHECK_CHAR_TABLE (table); @@ -2803,10 +2804,11 @@ if (!SUB_CHAR_TABLE_P (elt)) continue; dim = CHARSET_DIMENSION (i - 128); + chars = CHARSET_CHARS (i - 128); if (dim == 2) for (j = 32; j < SUB_CHAR_TABLE_ORDINARY_SLOTS; j++) - optimize_sub_char_table (XCHAR_TABLE (elt)->contents + j, dim); - optimize_sub_char_table (XCHAR_TABLE (table)->contents + i, dim); + optimize_sub_char_table (XCHAR_TABLE (elt)->contents + j, chars); + optimize_sub_char_table (XCHAR_TABLE (table)->contents + i, chars); } return Qnil; }