Mercurial > emacs
comparison lisp/international/mule.el @ 71158:90d8009144c1
(find-auto-coding): Fix previous change.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Fri, 02 Jun 2006 06:34:24 +0000 |
parents | bb2f67aa85f1 |
children | 3f87fbcb6f66 |
comparison
equal
deleted
inserted
replaced
71157:df6eeb0fe6f9 | 71158:90d8009144c1 |
---|---|
1705 ;; Head and tail are overlapped. | 1705 ;; Head and tail are overlapped. |
1706 (setq tail-found head-found) | 1706 (setq tail-found head-found) |
1707 (goto-char tail-start) | 1707 (goto-char tail-start) |
1708 (setq tail-found (or (search-forward "coding:" tail-end t) | 1708 (setq tail-found (or (search-forward "coding:" tail-end t) |
1709 (search-forward "unibyte:" tail-end t) | 1709 (search-forward "unibyte:" tail-end t) |
1710 (search-forward "char-trans:" tail-end t) | |
1710 (search-forward "enable-character-translation:" | 1711 (search-forward "enable-character-translation:" |
1711 tail-end t)))) | 1712 tail-end t)))) |
1712 | 1713 |
1713 ;; At first check the head. | 1714 ;; At first check the head. |
1714 (when head-found | 1715 (when head-found |
1759 "[ \t]*unibyte[ \t]*:[ \t]*\\([^ \t\r\n]+\\)[ \t]*" | 1760 "[ \t]*unibyte[ \t]*:[ \t]*\\([^ \t\r\n]+\\)[ \t]*" |
1760 suffix "[\r\n]")) | 1761 suffix "[\r\n]")) |
1761 (re-char-trans | 1762 (re-char-trans |
1762 (concat | 1763 (concat |
1763 "[\r\n]" prefix | 1764 "[\r\n]" prefix |
1764 "[ \t]*enable-character-translation[ \t]*:[ \t]*\\([^ \t\r\n]+\\)[ \t]*" | 1765 "[ \t]*\\(enable-character-translation\\|char-trans\\)[ \t]*:[ \t]*\\([^ \t\r\n]+\\)[ \t]*" |
1765 suffix "[\r\n]")) | 1766 suffix "[\r\n]")) |
1766 (re-end | 1767 (re-end |
1767 (concat "[\r\n]" prefix "[ \t]*End *:[ \t]*" suffix | 1768 (concat "[\r\n]" prefix "[ \t]*End *:[ \t]*" suffix |
1768 "[\r\n]?")) | 1769 "[\r\n]?")) |
1769 (pos (1- (point)))) | 1770 (pos (1- (point)))) |
1777 (when (and (not coding-system) | 1778 (when (and (not coding-system) |
1778 (re-search-forward re-coding tail-end t)) | 1779 (re-search-forward re-coding tail-end t)) |
1779 (setq coding-system (intern (match-string 1)))) | 1780 (setq coding-system (intern (match-string 1)))) |
1780 (when (and (not char-trans) | 1781 (when (and (not char-trans) |
1781 (re-search-forward re-char-trans tail-end t)) | 1782 (re-search-forward re-char-trans tail-end t)) |
1782 (setq char-trans (match-string 1)))))) | 1783 (setq char-trans (match-string 2)))))) |
1783 (if coding-system | 1784 (if coding-system |
1784 ;; If the coding-system name ends with "!", remove it and | 1785 ;; If the coding-system name ends with "!", remove it and |
1785 ;; set char-trans to "nil". | 1786 ;; set char-trans to "nil". |
1786 (let ((name (symbol-name coding-system))) | 1787 (let ((name (symbol-name coding-system))) |
1787 (if (= (aref name (1- (length name))) ?!) | 1788 (if (= (aref name (1- (length name))) ?!) |