diff options
| author | Kenichi Handa | 2006-05-18 02:19:01 +0000 |
|---|---|---|
| committer | Kenichi Handa | 2006-05-18 02:19:01 +0000 |
| commit | 0c2660c849293d23296f758c4a50f6e40432cf2e (patch) | |
| tree | a2edd54d8cbd47dc959345b0c748b778811f3b05 /src/coding.c | |
| parent | ad598c8b58dd85c94b23918b55091e0ea7f027bc (diff) | |
| download | emacs-0c2660c849293d23296f758c4a50f6e40432cf2e.tar.gz emacs-0c2660c849293d23296f758c4a50f6e40432cf2e.zip | |
(Qascii_incompatible): New variable.
(syms_of_coding): Setup Qascii_incompatible.
(setup_coding_system): Be sure to initialize coding->common_flags.
Check `ascii-incompatible' property of the coding system.
Diffstat (limited to 'src/coding.c')
| -rw-r--r-- | src/coding.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/coding.c b/src/coding.c index 155da568007..478e119c003 100644 --- a/src/coding.c +++ b/src/coding.c | |||
| @@ -363,6 +363,7 @@ Lisp_Object Qno_conversion, Qundecided; | |||
| 363 | Lisp_Object Qcoding_system_history; | 363 | Lisp_Object Qcoding_system_history; |
| 364 | Lisp_Object Qsafe_chars; | 364 | Lisp_Object Qsafe_chars; |
| 365 | Lisp_Object Qvalid_codes; | 365 | Lisp_Object Qvalid_codes; |
| 366 | Lisp_Object Qascii_incompatible; | ||
| 366 | 367 | ||
| 367 | extern Lisp_Object Qinsert_file_contents, Qwrite_region; | 368 | extern Lisp_Object Qinsert_file_contents, Qwrite_region; |
| 368 | Lisp_Object Qcall_process, Qcall_process_region; | 369 | Lisp_Object Qcall_process, Qcall_process_region; |
| @@ -3625,7 +3626,10 @@ setup_coding_system (coding_system, coding) | |||
| 3625 | = CODING_REQUIRE_DECODING_MASK | CODING_REQUIRE_ENCODING_MASK; | 3626 | = CODING_REQUIRE_DECODING_MASK | CODING_REQUIRE_ENCODING_MASK; |
| 3626 | } | 3627 | } |
| 3627 | else | 3628 | else |
| 3628 | coding->eol_type = CODING_EOL_LF; | 3629 | { |
| 3630 | coding->common_flags = 0; | ||
| 3631 | coding->eol_type = CODING_EOL_LF; | ||
| 3632 | } | ||
| 3629 | 3633 | ||
| 3630 | coding_type = XVECTOR (coding_spec)->contents[0]; | 3634 | coding_type = XVECTOR (coding_spec)->contents[0]; |
| 3631 | /* Try short cut. */ | 3635 | /* Try short cut. */ |
| @@ -3685,6 +3689,12 @@ setup_coding_system (coding_system, coding) | |||
| 3685 | if (!NILP (val)) | 3689 | if (!NILP (val)) |
| 3686 | coding->composing = COMPOSITION_NO; | 3690 | coding->composing = COMPOSITION_NO; |
| 3687 | 3691 | ||
| 3692 | /* If the coding system is ascii-incompatible, record it in | ||
| 3693 | common_flags. */ | ||
| 3694 | val = Fplist_get (plist, Qascii_incompatible); | ||
| 3695 | if (! NILP (val)) | ||
| 3696 | coding->common_flags |= CODING_ASCII_INCOMPATIBLE_MASK; | ||
| 3697 | |||
| 3688 | switch (XFASTINT (coding_type)) | 3698 | switch (XFASTINT (coding_type)) |
| 3689 | { | 3699 | { |
| 3690 | case 0: | 3700 | case 0: |
| @@ -7814,6 +7824,9 @@ syms_of_coding () | |||
| 7814 | Qvalid_codes = intern ("valid-codes"); | 7824 | Qvalid_codes = intern ("valid-codes"); |
| 7815 | staticpro (&Qvalid_codes); | 7825 | staticpro (&Qvalid_codes); |
| 7816 | 7826 | ||
| 7827 | Qascii_incompatible = intern ("ascii-incompatible"); | ||
| 7828 | staticpro (&Qascii_incompatible); | ||
| 7829 | |||
| 7817 | Qemacs_mule = intern ("emacs-mule"); | 7830 | Qemacs_mule = intern ("emacs-mule"); |
| 7818 | staticpro (&Qemacs_mule); | 7831 | staticpro (&Qemacs_mule); |
| 7819 | 7832 | ||