]> git.eshelyaron.com Git - emacs.git/commitdiff
lisp/gnus/mm-util.el (mm-make-temp-file): Alias to make-temp-file for modern Emacsen
authorKatsumi Yamaoka <yamaoka@jpl.org>
Tue, 17 Dec 2013 10:12:07 +0000 (10:12 +0000)
committerKatsumi Yamaoka <yamaoka@jpl.org>
Tue, 17 Dec 2013 10:12:07 +0000 (10:12 +0000)
lisp/gnus/ChangeLog
lisp/gnus/mm-util.el

index 83b66f78f6491d6c02987aa539a493117da79ba9..7cee21522b6cb3111359265555740116bcff0735 100644 (file)
@@ -1,3 +1,8 @@
+2013-12-17  Katsumi Yamaoka  <yamaoka@jpl.org>
+
+       * mm-util.el (mm-make-temp-file):
+       Alias to make-temp-file for modern Emacsen.
+
 2013-12-08  Katsumi Yamaoka  <yamaoka@jpl.org>
 
        * gnus-msg.el (gnus-setup-message): Fix the type of argument passed to
index 5b0fd6860a0878f469e5ff445b4ee067695d23d4..7ccf1c9e9eea2295a67588b68b0ae265526b3dd5 100644 (file)
@@ -1382,13 +1382,12 @@ If INHIBIT is non-nil, inhibit `mm-inhibit-file-name-handlers'."
 ;; It is not a MIME function, but some MIME functions use it.
 (if (and (fboundp 'make-temp-file)
         (ignore-errors
-          (let ((def (symbol-function 'make-temp-file)))
-            (and (byte-code-function-p def)
-                 (setq def (if (fboundp 'compiled-function-arglist)
-                               ;; XEmacs
-                               (eval (list 'compiled-function-arglist def))
-                             (aref def 0)))
-                 (>= (length def) 4)
+          (let ((def (if (fboundp 'compiled-function-arglist) ;; XEmacs
+                         (eval (list 'compiled-function-arglist
+                                     (symbol-function 'make-temp-file)))
+                       (require 'help-fns)
+                       (help-function-arglist 'make-temp-file t))))
+            (and (>= (length def) 4)
                  (eq (nth 3 def) 'suffix)))))
     (defalias 'mm-make-temp-file 'make-temp-file)
   ;; Stolen (and modified for XEmacs) from Emacs 22.