comparison src/coding.c @ 89468:7dbbe692f70c

* coding.c (QCcategory): New variable. (syms_of_coding): Defsym it. Set all elements of Vcoding_category_table and their symbol values. (Fset_coding_system_priority): Doc fix. Update symbol qvalues of coding-category-XXX, and coding-category-list. (Fdefine_coding_system_internal): Add category in the plist.
author Kenichi Handa <handa@m17n.org>
date Fri, 06 Jun 2003 02:13:16 +0000
parents e911ca706166
children 4896b8834fb6
comparison
equal deleted inserted replaced
89467:e911ca706166 89468:7dbbe692f70c
309 Lisp_Object Qno_conversion, Qundecided; 309 Lisp_Object Qno_conversion, Qundecided;
310 Lisp_Object Qcharset, Qiso_2022, Qutf_8, Qutf_16, Qshift_jis, Qbig5; 310 Lisp_Object Qcharset, Qiso_2022, Qutf_8, Qutf_16, Qshift_jis, Qbig5;
311 Lisp_Object Qbig, Qlittle; 311 Lisp_Object Qbig, Qlittle;
312 Lisp_Object Qcoding_system_history; 312 Lisp_Object Qcoding_system_history;
313 Lisp_Object Qvalid_codes; 313 Lisp_Object Qvalid_codes;
314 Lisp_Object QCcategory;
314 315
315 extern Lisp_Object Qinsert_file_contents, Qwrite_region; 316 extern Lisp_Object Qinsert_file_contents, Qwrite_region;
316 Lisp_Object Qcall_process, Qcall_process_region, Qprocess_argument; 317 Lisp_Object Qcall_process, Qcall_process_region, Qprocess_argument;
317 Lisp_Object Qstart_process, Qopen_network_stream; 318 Lisp_Object Qstart_process, Qopen_network_stream;
318 Lisp_Object Qtarget_idx; 319 Lisp_Object Qtarget_idx;
8311 else 8312 else
8312 error ("Invalid coding system type: %s", 8313 error ("Invalid coding system type: %s",
8313 XSYMBOL (coding_type)->name->data); 8314 XSYMBOL (coding_type)->name->data);
8314 8315
8315 CODING_ATTR_CATEGORY (attrs) = make_number (category); 8316 CODING_ATTR_CATEGORY (attrs) = make_number (category);
8317 CODING_ATTR_PLIST (attrs)
8318 = Fcons (QCcategory, Fcons (AREF (Vcoding_category_table, category),
8319 CODING_ATTR_PLIST (attrs)));
8316 8320
8317 eol_type = args[coding_arg_eol_type]; 8321 eol_type = args[coding_arg_eol_type];
8318 if (! NILP (eol_type) 8322 if (! NILP (eol_type)
8319 && ! EQ (eol_type, Qunix) 8323 && ! EQ (eol_type, Qunix)
8320 && ! EQ (eol_type, Qdos) 8324 && ! EQ (eol_type, Qdos)
8620 DEFSYM (Qtranslation_table_for_encode, "translation-table-for-encode"); 8624 DEFSYM (Qtranslation_table_for_encode, "translation-table-for-encode");
8621 8625
8622 DEFSYM (Qvalid_codes, "valid-codes"); 8626 DEFSYM (Qvalid_codes, "valid-codes");
8623 8627
8624 DEFSYM (Qemacs_mule, "emacs-mule"); 8628 DEFSYM (Qemacs_mule, "emacs-mule");
8629
8630 DEFSYM (QCcategory, ":category");
8625 8631
8626 Vcoding_category_table 8632 Vcoding_category_table
8627 = Fmake_vector (make_number (coding_category_max), Qnil); 8633 = Fmake_vector (make_number (coding_category_max), Qnil);
8628 staticpro (&Vcoding_category_table); 8634 staticpro (&Vcoding_category_table);
8629 /* Followings are target of code detection. */ 8635 /* Followings are target of code detection. */