diff options
| author | Dan Nicolaescu | 2009-11-06 06:50:52 +0000 |
|---|---|---|
| committer | Dan Nicolaescu | 2009-11-06 06:50:52 +0000 |
| commit | d67b4f80dbe514d6e351e7d89c78921c85e7dbe7 (patch) | |
| tree | da83a5dc49e499e330365feaa8123709fdf0cc88 /src/coding.c | |
| parent | 495bd5ca19cf79a9e91b77bf2e2ea37b8be3ef1f (diff) | |
| download | emacs-d67b4f80dbe514d6e351e7d89c78921c85e7dbe7.tar.gz emacs-d67b4f80dbe514d6e351e7d89c78921c85e7dbe7.zip | |
* xterm.c (syms_of_xterm):
* xselect.c (syms_of_xselect):
* xmenu.c (syms_of_xmenu):
* xfns.c (syms_of_xfns):
* xfaces.c (syms_of_xfaces):
* xdisp.c (syms_of_xdisp):
* window.c (syms_of_window):
* w32fns.c (syms_of_w32fns):
* undo.c (syms_of_undo):
* textprop.c (syms_of_textprop):
* terminal.c (syms_of_terminal):
* syntax.c (syms_of_syntax):
* sound.c (syms_of_sound):
* search.c (syms_of_search):
* print.c (syms_of_print):
* minibuf.c (syms_of_minibuf):
* macros.c (syms_of_macros):
* keymap.c (syms_of_keymap, initial_define_key)
(initial_define_lispy_key):
* keyboard.c (syms_of_keyboard):
* insdel.c (syms_of_insdel):
* image.c (syms_of_image):
* fringe.c (syms_of_fringe):
* frame.c (syms_of_frame):
* fontset.c (syms_of_fontset):
* fns.c (syms_of_fns):
* fns.c (syms_of_fns):
* fileio.c (syms_of_fileio):
* fileio.c (syms_of_fileio):
* eval.c (syms_of_eval):
* doc.c (syms_of_doc):
* dispnew.c (syms_of_display):
* dired.c (syms_of_dired):
* dbusbind.c (syms_of_dbusbind):
* data.c (syms_of_data):
* composite.c (syms_of_composite):
* coding.c (syms_of_coding):
* cmds.c (syms_of_cmds):
* charset.c (define_charset_internal, syms_of_character):
* ccl.c (syms_of_ccl):
* category.c (syms_of_category, init_category_once):
* casetab.c (syms_of_casetab):
* casefiddle.c (syms_of_casefiddle):
* callint.c (syms_of_callint):
* bytecode.c (syms_of_bytecode):
* buffer.c (keys_of_buffer, syms_of_buffer):
* alloc.c (syms_of_alloc):
* process.c (syms_of_process, init_process):
* lread.c (syms_of_lread, init_obarray):
* font.c (build_style_table):
* emacs.c (syms_of_emacs, main): Replace calls to intern with
intern_c_string, calls to make_pure_string with
make_pure_c_string. Use pure_cons instead of Fcons.
* process.c (socket_options): Make it const.
(set_socket_option, init_process): Use a const pointer.
* lread.c (intern_c_string): New function.
(defvar_kboard, defvar_lisp, defvar_lisp_nopro, defvar_bool)
(defvar_int): Uset it. Make the name const char*.
* font.c (struct table_entry): Remove unused member. Make NAMES
constant.
(weight_table, slant_table, width_table): Make constant.
* emacs.c (struct standard_args): Make name and longname constant.
Diffstat (limited to 'src/coding.c')
| -rw-r--r-- | src/coding.c | 80 |
1 files changed, 40 insertions, 40 deletions
diff --git a/src/coding.c b/src/coding.c index 678bafaa9ea..b13766e3076 100644 --- a/src/coding.c +++ b/src/coding.c | |||
| @@ -10415,7 +10415,7 @@ syms_of_coding () | |||
| 10415 | Vcode_conversion_reused_workbuf = Qnil; | 10415 | Vcode_conversion_reused_workbuf = Qnil; |
| 10416 | 10416 | ||
| 10417 | staticpro (&Vcode_conversion_workbuf_name); | 10417 | staticpro (&Vcode_conversion_workbuf_name); |
| 10418 | Vcode_conversion_workbuf_name = build_string (" *code-conversion-work*"); | 10418 | Vcode_conversion_workbuf_name = make_pure_c_string (" *code-conversion-work*"); |
| 10419 | 10419 | ||
| 10420 | reused_workbuf_in_use = 0; | 10420 | reused_workbuf_in_use = 0; |
| 10421 | 10421 | ||
| @@ -10476,14 +10476,14 @@ syms_of_coding () | |||
| 10476 | 10476 | ||
| 10477 | DEFSYM (Qcoding_system_error, "coding-system-error"); | 10477 | DEFSYM (Qcoding_system_error, "coding-system-error"); |
| 10478 | Fput (Qcoding_system_error, Qerror_conditions, | 10478 | Fput (Qcoding_system_error, Qerror_conditions, |
| 10479 | Fcons (Qcoding_system_error, Fcons (Qerror, Qnil))); | 10479 | pure_cons (Qcoding_system_error, pure_cons (Qerror, Qnil))); |
| 10480 | Fput (Qcoding_system_error, Qerror_message, | 10480 | Fput (Qcoding_system_error, Qerror_message, |
| 10481 | build_string ("Invalid coding system")); | 10481 | make_pure_c_string ("Invalid coding system")); |
| 10482 | 10482 | ||
| 10483 | /* Intern this now in case it isn't already done. | 10483 | /* Intern this now in case it isn't already done. |
| 10484 | Setting this variable twice is harmless. | 10484 | Setting this variable twice is harmless. |
| 10485 | But don't staticpro it here--that is done in alloc.c. */ | 10485 | But don't staticpro it here--that is done in alloc.c. */ |
| 10486 | Qchar_table_extra_slots = intern ("char-table-extra-slots"); | 10486 | Qchar_table_extra_slots = intern_c_string ("char-table-extra-slots"); |
| 10487 | 10487 | ||
| 10488 | DEFSYM (Qtranslation_table, "translation-table"); | 10488 | DEFSYM (Qtranslation_table, "translation-table"); |
| 10489 | Fput (Qtranslation_table, Qchar_table_extra_slots, make_number (2)); | 10489 | Fput (Qtranslation_table, Qchar_table_extra_slots, make_number (2)); |
| @@ -10509,48 +10509,48 @@ syms_of_coding () | |||
| 10509 | staticpro (&Vcoding_category_table); | 10509 | staticpro (&Vcoding_category_table); |
| 10510 | /* Followings are target of code detection. */ | 10510 | /* Followings are target of code detection. */ |
| 10511 | ASET (Vcoding_category_table, coding_category_iso_7, | 10511 | ASET (Vcoding_category_table, coding_category_iso_7, |
| 10512 | intern ("coding-category-iso-7")); | 10512 | intern_c_string ("coding-category-iso-7")); |
| 10513 | ASET (Vcoding_category_table, coding_category_iso_7_tight, | 10513 | ASET (Vcoding_category_table, coding_category_iso_7_tight, |
| 10514 | intern ("coding-category-iso-7-tight")); | 10514 | intern_c_string ("coding-category-iso-7-tight")); |
| 10515 | ASET (Vcoding_category_table, coding_category_iso_8_1, | 10515 | ASET (Vcoding_category_table, coding_category_iso_8_1, |
| 10516 | intern ("coding-category-iso-8-1")); | 10516 | intern_c_string ("coding-category-iso-8-1")); |
| 10517 | ASET (Vcoding_category_table, coding_category_iso_8_2, | 10517 | ASET (Vcoding_category_table, coding_category_iso_8_2, |
| 10518 | intern ("coding-category-iso-8-2")); | 10518 | intern_c_string ("coding-category-iso-8-2")); |
| 10519 | ASET (Vcoding_category_table, coding_category_iso_7_else, | 10519 | ASET (Vcoding_category_table, coding_category_iso_7_else, |
| 10520 | intern ("coding-category-iso-7-else")); | 10520 | intern_c_string ("coding-category-iso-7-else")); |
| 10521 | ASET (Vcoding_category_table, coding_category_iso_8_else, | 10521 | ASET (Vcoding_category_table, coding_category_iso_8_else, |
| 10522 | intern ("coding-category-iso-8-else")); | 10522 | intern_c_string ("coding-category-iso-8-else")); |
| 10523 | ASET (Vcoding_category_table, coding_category_utf_8_auto, | 10523 | ASET (Vcoding_category_table, coding_category_utf_8_auto, |
| 10524 | intern ("coding-category-utf-8-auto")); | 10524 | intern_c_string ("coding-category-utf-8-auto")); |
| 10525 | ASET (Vcoding_category_table, coding_category_utf_8_nosig, | 10525 | ASET (Vcoding_category_table, coding_category_utf_8_nosig, |
| 10526 | intern ("coding-category-utf-8")); | 10526 | intern_c_string ("coding-category-utf-8")); |
| 10527 | ASET (Vcoding_category_table, coding_category_utf_8_sig, | 10527 | ASET (Vcoding_category_table, coding_category_utf_8_sig, |
| 10528 | intern ("coding-category-utf-8-sig")); | 10528 | intern_c_string ("coding-category-utf-8-sig")); |
| 10529 | ASET (Vcoding_category_table, coding_category_utf_16_be, | 10529 | ASET (Vcoding_category_table, coding_category_utf_16_be, |
| 10530 | intern ("coding-category-utf-16-be")); | 10530 | intern_c_string ("coding-category-utf-16-be")); |
| 10531 | ASET (Vcoding_category_table, coding_category_utf_16_auto, | 10531 | ASET (Vcoding_category_table, coding_category_utf_16_auto, |
| 10532 | intern ("coding-category-utf-16-auto")); | 10532 | intern_c_string ("coding-category-utf-16-auto")); |
| 10533 | ASET (Vcoding_category_table, coding_category_utf_16_le, | 10533 | ASET (Vcoding_category_table, coding_category_utf_16_le, |
| 10534 | intern ("coding-category-utf-16-le")); | 10534 | intern_c_string ("coding-category-utf-16-le")); |
| 10535 | ASET (Vcoding_category_table, coding_category_utf_16_be_nosig, | 10535 | ASET (Vcoding_category_table, coding_category_utf_16_be_nosig, |
| 10536 | intern ("coding-category-utf-16-be-nosig")); | 10536 | intern_c_string ("coding-category-utf-16-be-nosig")); |
| 10537 | ASET (Vcoding_category_table, coding_category_utf_16_le_nosig, | 10537 | ASET (Vcoding_category_table, coding_category_utf_16_le_nosig, |
| 10538 | intern ("coding-category-utf-16-le-nosig")); | 10538 | intern_c_string ("coding-category-utf-16-le-nosig")); |
| 10539 | ASET (Vcoding_category_table, coding_category_charset, | 10539 | ASET (Vcoding_category_table, coding_category_charset, |
| 10540 | intern ("coding-category-charset")); | 10540 | intern_c_string ("coding-category-charset")); |
| 10541 | ASET (Vcoding_category_table, coding_category_sjis, | 10541 | ASET (Vcoding_category_table, coding_category_sjis, |
| 10542 | intern ("coding-category-sjis")); | 10542 | intern_c_string ("coding-category-sjis")); |
| 10543 | ASET (Vcoding_category_table, coding_category_big5, | 10543 | ASET (Vcoding_category_table, coding_category_big5, |
| 10544 | intern ("coding-category-big5")); | 10544 | intern_c_string ("coding-category-big5")); |
| 10545 | ASET (Vcoding_category_table, coding_category_ccl, | 10545 | ASET (Vcoding_category_table, coding_category_ccl, |
| 10546 | intern ("coding-category-ccl")); | 10546 | intern_c_string ("coding-category-ccl")); |
| 10547 | ASET (Vcoding_category_table, coding_category_emacs_mule, | 10547 | ASET (Vcoding_category_table, coding_category_emacs_mule, |
| 10548 | intern ("coding-category-emacs-mule")); | 10548 | intern_c_string ("coding-category-emacs-mule")); |
| 10549 | /* Followings are NOT target of code detection. */ | 10549 | /* Followings are NOT target of code detection. */ |
| 10550 | ASET (Vcoding_category_table, coding_category_raw_text, | 10550 | ASET (Vcoding_category_table, coding_category_raw_text, |
| 10551 | intern ("coding-category-raw-text")); | 10551 | intern_c_string ("coding-category-raw-text")); |
| 10552 | ASET (Vcoding_category_table, coding_category_undecided, | 10552 | ASET (Vcoding_category_table, coding_category_undecided, |
| 10553 | intern ("coding-category-undecided")); | 10553 | intern_c_string ("coding-category-undecided")); |
| 10554 | 10554 | ||
| 10555 | DEFSYM (Qinsufficient_source, "insufficient-source"); | 10555 | DEFSYM (Qinsufficient_source, "insufficient-source"); |
| 10556 | DEFSYM (Qinconsistent_eol, "inconsistent-eol"); | 10556 | DEFSYM (Qinconsistent_eol, "inconsistent-eol"); |
| @@ -10751,22 +10751,22 @@ Also used for decoding keyboard input on X Window system. */); | |||
| 10751 | DEFVAR_LISP ("eol-mnemonic-unix", &eol_mnemonic_unix, | 10751 | DEFVAR_LISP ("eol-mnemonic-unix", &eol_mnemonic_unix, |
| 10752 | doc: /* | 10752 | doc: /* |
| 10753 | *String displayed in mode line for UNIX-like (LF) end-of-line format. */); | 10753 | *String displayed in mode line for UNIX-like (LF) end-of-line format. */); |
| 10754 | eol_mnemonic_unix = build_string (":"); | 10754 | eol_mnemonic_unix = make_pure_c_string (":"); |
| 10755 | 10755 | ||
| 10756 | DEFVAR_LISP ("eol-mnemonic-dos", &eol_mnemonic_dos, | 10756 | DEFVAR_LISP ("eol-mnemonic-dos", &eol_mnemonic_dos, |
| 10757 | doc: /* | 10757 | doc: /* |
| 10758 | *String displayed in mode line for DOS-like (CRLF) end-of-line format. */); | 10758 | *String displayed in mode line for DOS-like (CRLF) end-of-line format. */); |
| 10759 | eol_mnemonic_dos = build_string ("\\"); | 10759 | eol_mnemonic_dos = make_pure_c_string ("\\"); |
| 10760 | 10760 | ||
| 10761 | DEFVAR_LISP ("eol-mnemonic-mac", &eol_mnemonic_mac, | 10761 | DEFVAR_LISP ("eol-mnemonic-mac", &eol_mnemonic_mac, |
| 10762 | doc: /* | 10762 | doc: /* |
| 10763 | *String displayed in mode line for MAC-like (CR) end-of-line format. */); | 10763 | *String displayed in mode line for MAC-like (CR) end-of-line format. */); |
| 10764 | eol_mnemonic_mac = build_string ("/"); | 10764 | eol_mnemonic_mac = make_pure_c_string ("/"); |
| 10765 | 10765 | ||
| 10766 | DEFVAR_LISP ("eol-mnemonic-undecided", &eol_mnemonic_undecided, | 10766 | DEFVAR_LISP ("eol-mnemonic-undecided", &eol_mnemonic_undecided, |
| 10767 | doc: /* | 10767 | doc: /* |
| 10768 | *String displayed in mode line when end-of-line format is not yet determined. */); | 10768 | *String displayed in mode line when end-of-line format is not yet determined. */); |
| 10769 | eol_mnemonic_undecided = build_string (":"); | 10769 | eol_mnemonic_undecided = make_pure_c_string (":"); |
| 10770 | 10770 | ||
| 10771 | DEFVAR_LISP ("enable-character-translation", &Venable_character_translation, | 10771 | DEFVAR_LISP ("enable-character-translation", &Venable_character_translation, |
| 10772 | doc: /* | 10772 | doc: /* |
| @@ -10891,25 +10891,25 @@ internal character representation. */); | |||
| 10891 | for (i = 0; i < coding_arg_max; i++) | 10891 | for (i = 0; i < coding_arg_max; i++) |
| 10892 | args[i] = Qnil; | 10892 | args[i] = Qnil; |
| 10893 | 10893 | ||
| 10894 | plist[0] = intern (":name"); | 10894 | plist[0] = intern_c_string (":name"); |
| 10895 | plist[1] = args[coding_arg_name] = Qno_conversion; | 10895 | plist[1] = args[coding_arg_name] = Qno_conversion; |
| 10896 | plist[2] = intern (":mnemonic"); | 10896 | plist[2] = intern_c_string (":mnemonic"); |
| 10897 | plist[3] = args[coding_arg_mnemonic] = make_number ('='); | 10897 | plist[3] = args[coding_arg_mnemonic] = make_number ('='); |
| 10898 | plist[4] = intern (":coding-type"); | 10898 | plist[4] = intern_c_string (":coding-type"); |
| 10899 | plist[5] = args[coding_arg_coding_type] = Qraw_text; | 10899 | plist[5] = args[coding_arg_coding_type] = Qraw_text; |
| 10900 | plist[6] = intern (":ascii-compatible-p"); | 10900 | plist[6] = intern_c_string (":ascii-compatible-p"); |
| 10901 | plist[7] = args[coding_arg_ascii_compatible_p] = Qt; | 10901 | plist[7] = args[coding_arg_ascii_compatible_p] = Qt; |
| 10902 | plist[8] = intern (":default-char"); | 10902 | plist[8] = intern_c_string (":default-char"); |
| 10903 | plist[9] = args[coding_arg_default_char] = make_number (0); | 10903 | plist[9] = args[coding_arg_default_char] = make_number (0); |
| 10904 | plist[10] = intern (":for-unibyte"); | 10904 | plist[10] = intern_c_string (":for-unibyte"); |
| 10905 | plist[11] = args[coding_arg_for_unibyte] = Qt; | 10905 | plist[11] = args[coding_arg_for_unibyte] = Qt; |
| 10906 | plist[12] = intern (":docstring"); | 10906 | plist[12] = intern_c_string (":docstring"); |
| 10907 | plist[13] = build_string ("Do no conversion.\n\ | 10907 | plist[13] = make_pure_c_string ("Do no conversion.\n\ |
| 10908 | \n\ | 10908 | \n\ |
| 10909 | When you visit a file with this coding, the file is read into a\n\ | 10909 | When you visit a file with this coding, the file is read into a\n\ |
| 10910 | unibyte buffer as is, thus each byte of a file is treated as a\n\ | 10910 | unibyte buffer as is, thus each byte of a file is treated as a\n\ |
| 10911 | character."); | 10911 | character."); |
| 10912 | plist[14] = intern (":eol-type"); | 10912 | plist[14] = intern_c_string (":eol-type"); |
| 10913 | plist[15] = args[coding_arg_eol_type] = Qunix; | 10913 | plist[15] = args[coding_arg_eol_type] = Qunix; |
| 10914 | args[coding_arg_plist] = Flist (16, plist); | 10914 | args[coding_arg_plist] = Flist (16, plist); |
| 10915 | Fdefine_coding_system_internal (coding_arg_max, args); | 10915 | Fdefine_coding_system_internal (coding_arg_max, args); |
| @@ -10919,10 +10919,10 @@ character."); | |||
| 10919 | plist[5] = args[coding_arg_coding_type] = Qundecided; | 10919 | plist[5] = args[coding_arg_coding_type] = Qundecided; |
| 10920 | /* This is already set. | 10920 | /* This is already set. |
| 10921 | plist[7] = args[coding_arg_ascii_compatible_p] = Qt; */ | 10921 | plist[7] = args[coding_arg_ascii_compatible_p] = Qt; */ |
| 10922 | plist[8] = intern (":charset-list"); | 10922 | plist[8] = intern_c_string (":charset-list"); |
| 10923 | plist[9] = args[coding_arg_charset_list] = Fcons (Qascii, Qnil); | 10923 | plist[9] = args[coding_arg_charset_list] = Fcons (Qascii, Qnil); |
| 10924 | plist[11] = args[coding_arg_for_unibyte] = Qnil; | 10924 | plist[11] = args[coding_arg_for_unibyte] = Qnil; |
| 10925 | plist[13] = build_string ("No conversion on encoding, automatic conversion on decoding."); | 10925 | plist[13] = make_pure_c_string ("No conversion on encoding, automatic conversion on decoding."); |
| 10926 | plist[15] = args[coding_arg_eol_type] = Qnil; | 10926 | plist[15] = args[coding_arg_eol_type] = Qnil; |
| 10927 | args[coding_arg_plist] = Flist (16, plist); | 10927 | args[coding_arg_plist] = Flist (16, plist); |
| 10928 | Fdefine_coding_system_internal (coding_arg_max, args); | 10928 | Fdefine_coding_system_internal (coding_arg_max, args); |