]> code.delx.au - gnu-emacs/commit
New C macro AUTO_STRING_WITH_LEN
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 4 Apr 2016 17:30:41 +0000 (10:30 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 4 Apr 2016 17:31:25 +0000 (10:31 -0700)
commit17cb263adb7c37803140604f0a2e4df8a38fbcff
treebd57929386123132847718e2d30a528c8b19d1a3
parent0322457e2bec0b9409a03887a8235dbe14e357f4
New C macro AUTO_STRING_WITH_LEN

Put a bit less pressure on the garbage collector by defining a
macro that is like AUTO_STRING but also allows null bytes in strings,
and by extending AUTO_STRING to work with any unibyte string.
* src/alloc.c (verify_ascii): Remove; all uses removed.
AUTO_STRING can now be used on non-ASCII unibyte strings.
* src/lisp.h (AUTO_STRING): Now allows non-ASCII unibyte strings.
(AUTO_STRING_WITH_LEN): New macro.
* src/coding.c (from_unicode_buffer):
* src/editfns.c (format_time_string):
* src/emacs-module.c (module_make_string, module_format_fun_env):
* src/fileio.c (Fexpand_file_name):
* src/font.c (font_parse_family_registry):
* src/ftfont.c (ftfont_get_charset):
* src/keymap.c (silly_event_symbol_error):
* src/menu.c (single_menu_item):
* src/sysdep.c (system_process_attributes):
Use AUTO_STRING_WITH_LEN if possible.
* src/emacs-module.c (module_make_function):
* src/fileio.c (report_file_errno, report_file_notify_error):
* src/fns.c (Flocale_info):
* src/sysdep.c (system_process_attributes):
Use AUTO_STRING if possible.  This is doable more often now
that AUTO_STRING works on any unibyte string.
12 files changed:
src/alloc.c
src/coding.c
src/editfns.c
src/emacs-module.c
src/fileio.c
src/fns.c
src/font.c
src/ftfont.c
src/keymap.c
src/lisp.h
src/menu.c
src/sysdep.c