summaryrefslogtreecommitdiff
path: root/lisp/gnus/mm-util.el
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>2006-12-07 04:14:14 +0000
committerMiles Bader <miles@gnu.org>2006-12-07 04:14:14 +0000
commita0451a715e4ed018a02b825d0eb823424693d1de (patch)
treed2b10fcc69c333ccc438d7a9ad116fbc1495fc9e /lisp/gnus/mm-util.el
parentd324f894beea8b485792c779659e8e20c1cb699d (diff)
parent12f7728e938fe5bb850ce2928637d1e349919142 (diff)
downloademacs-a0451a715e4ed018a02b825d0eb823424693d1de.tar.gz
Merge from emacs--devo--0
Patches applied: * emacs--devo--0 (patch 523-544) - Update from CVS - Merge from gnus--rel--5.10 * gnus--rel--5.10 (patch 168-171) - Update from CVS - Merge from emacs--devo--0 Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-150
Diffstat (limited to 'lisp/gnus/mm-util.el')
-rw-r--r--lisp/gnus/mm-util.el19
1 files changed, 13 insertions, 6 deletions
diff --git a/lisp/gnus/mm-util.el b/lisp/gnus/mm-util.el
index 54f5612a72d..402e824af23 100644
--- a/lisp/gnus/mm-util.el
+++ b/lisp/gnus/mm-util.el
@@ -92,12 +92,6 @@
;; (string-to-multibyte s) ~= (decode-coding-string s 'binary)
;; (string-make-multibyte s) ~= (decode-coding-string s locale-coding-system)
(string-as-multibyte . identity)
- (string-to-multibyte
- . (lambda (string)
- "Return a multibyte string with the same individual chars as string."
- (mapconcat
- (lambda (ch) (mm-string-as-multibyte (char-to-string ch)))
- string "")))
(multibyte-string-p . ignore)
(insert-byte . insert-char)
(multibyte-char-to-unibyte . identity))))
@@ -128,6 +122,19 @@ This is a compatibility function for different Emacsen."
(setq start (- (length string) tail))))
string))))
+(defalias 'mm-string-to-multibyte
+ (cond
+ ((featurep 'xemacs)
+ 'identity)
+ ((fboundp 'string-to-multibyte)
+ 'string-to-multibyte)
+ (t
+ (lambda (string)
+ "Return a multibyte string with the same individual chars as string."
+ (mapconcat
+ (lambda (ch) (mm-string-as-multibyte (char-to-string ch)))
+ string "")))))
+
(eval-and-compile
(defalias 'mm-char-or-char-int-p
(cond