From: morioka Date: Sat, 10 Oct 1998 01:40:32 +0000 (+0000) Subject: (write-region-as-binary): bind `jka-compr-compression-info-list' with X-Git-Tag: apel-9_2~4 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d29c16f55582e719c85bb668bf354cea49bd320d;p=elisp%2Fapel.git (write-region-as-binary): bind `jka-compr-compression-info-list' with nil. (insert-file-contents-as-binary): Change to alias of `insert-file-contents-literally' for Emacs 20. --- diff --git a/poem-20.el b/poem-20.el index 33acef7..6e4158a 100644 --- a/poem-20.el +++ b/poem-20.el @@ -49,21 +49,13 @@ (defun write-region-as-binary (start end filename &optional append visit lockname) "Like `write-region', q.v., but don't encode." - (let ((coding-system-for-write 'binary)) + (let ((coding-system-for-write 'binary) + jka-compr-compression-info-list) (write-region start end filename append visit lockname))) -(defun insert-file-contents-as-binary (filename - &optional visit beg end replace) - "Like `insert-file-contents', q.v., but don't code and format conversion. -Like `insert-file-contents-literary', but it allows find-file-hooks, -automatic uncompression, etc. - -Namely this function ensures that only format decoding and character -code conversion will not take place." - (let ((coding-system-for-read 'binary) - format-alist) - ;; Returns list of absolute file name and length of data inserted. - (insert-file-contents filename visit beg end replace))) +;; `insert-file-contents-literally' of Emacs 20 supports +;; `file-name-handler-alist'. +(defalias 'insert-file-contents-as-binary 'insert-file-contents-literally) (defun insert-file-contents-as-raw-text (filename &optional visit beg end replace)