Mercurial > emacs
changeset 85243:2869af9a0789
(Fregister_ccl_program, Fregister_code_conversion_map): Use larger_vector.
author | Eli Zaretskii <eliz@gnu.org> |
---|---|
date | Sat, 13 Oct 2007 12:06:41 +0000 |
parents | 9b00632ffdf2 |
children | 8a6c1b0352a2 |
files | src/ccl.c |
diffstat | 1 files changed, 4 insertions(+), 19 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ccl.c Sat Oct 13 12:06:04 2007 +0000 +++ b/src/ccl.c Sat Oct 13 12:06:41 2007 +0000 @@ -2348,16 +2348,8 @@ } if (idx == len) - { - /* Extend the table. */ - Lisp_Object new_table; - int j; - - new_table = Fmake_vector (make_number (len * 2), Qnil); - for (j = 0; j < len; j++) - ASET (new_table, j, AREF (Vccl_program_table, j)); - Vccl_program_table = new_table; - } + /* Extend the table. */ + Vccl_program_table = larger_vector (Vccl_program_table, len * 2, Qnil); { Lisp_Object elt; @@ -2416,15 +2408,8 @@ } if (i == len) - { - Lisp_Object new_vector = Fmake_vector (make_number (len * 2), Qnil); - int j; - - for (j = 0; j < len; j++) - AREF (new_vector, j) - = AREF (Vcode_conversion_map_vector, j); - Vcode_conversion_map_vector = new_vector; - } + Vcode_conversion_map_vector = larger_vector + (Vcode_conversion_map_vector, len * 2, Qnil); index = make_number (i); Fput (symbol, Qcode_conversion_map, map);