diff options
| author | Kenichi Handa | 2006-01-19 07:16:47 +0000 |
|---|---|---|
| committer | Kenichi Handa | 2006-01-19 07:16:47 +0000 |
| commit | 2da14137b65ad7c7fab34dcac8e10e16703c96d1 (patch) | |
| tree | dada0cb42dfb7f2f9fedcaf610944fb02a070b40 /lisp | |
| parent | 87e7795ecea5c89342917bb3de23995a49742195 (diff) | |
| download | emacs-2da14137b65ad7c7fab34dcac8e10e16703c96d1.tar.gz emacs-2da14137b65ad7c7fab34dcac8e10e16703c96d1.zip | |
(autoload-coding-system): Install the same
function as in HEAD.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/international/mule.el | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/lisp/international/mule.el b/lisp/international/mule.el index ad3ee1174d9..a9569119094 100644 --- a/lisp/international/mule.el +++ b/lisp/international/mule.el | |||
| @@ -1126,6 +1126,18 @@ Return the resulting coding system." | |||
| 1126 | first eol))) | 1126 | first eol))) |
| 1127 | first)) | 1127 | first)) |
| 1128 | 1128 | ||
| 1129 | (defun autoload-coding-system (symbol form) | ||
| 1130 | "Define SYMBOL as a coding-system that is defined on demand. | ||
| 1131 | |||
| 1132 | FROM is a form to evaluate to define the coding-system." | ||
| 1133 | (put symbol 'coding-system-define-form form) | ||
| 1134 | (setq coding-system-alist (cons (list (symbol-name symbol)) | ||
| 1135 | coding-system-alist)) | ||
| 1136 | (dolist (elt '("-unix" "-dos" "-mac")) | ||
| 1137 | (let ((name (concat (symbol-name symbol) elt))) | ||
| 1138 | (put (intern name) 'coding-system-define-form form) | ||
| 1139 | (setq coding-system-alist (cons (list name) coding-system-alist))))) | ||
| 1140 | |||
| 1129 | (defun set-buffer-file-coding-system (coding-system &optional force nomodify) | 1141 | (defun set-buffer-file-coding-system (coding-system &optional force nomodify) |
| 1130 | "Set the file coding-system of the current buffer to CODING-SYSTEM. | 1142 | "Set the file coding-system of the current buffer to CODING-SYSTEM. |
| 1131 | This means that when you save the buffer, it will be converted | 1143 | This means that when you save the buffer, it will be converted |