diff lisp/mule/mule-coding.el @ 104:cf808b4c4290 r20-1b4

Import from CVS: tag r20-1b4
author cvs
date Mon, 13 Aug 2007 09:16:51 +0200
parents a145efe76779
children 8619ce7e4c50
line wrap: on
line diff
--- a/lisp/mule/mule-coding.el	Mon Aug 13 09:15:51 2007 +0200
+++ b/lisp/mule/mule-coding.el	Mon Aug 13 09:16:51 2007 +0200
@@ -54,23 +54,6 @@
   (interactive "r\nP")
   (princ (detect-coding-region start end)))
 
-(defmacro with-string-as-buffer-contents (str &rest body)
-  "With the contents of the current buffer being STR, run BODY.
-Returns the new contents of the buffer, as modified by BODY.
-The original current buffer is restored afterwards."
-  `(let ((curbuf (current-buffer))
-         (tempbuf (get-buffer-create " *string-as-buffer-contents*")))
-     (unwind-protect
-         (progn
-           (set-buffer tempbuf)
-           (buffer-disable-undo (current-buffer))
-           (erase-buffer)
-           (insert ,str)
-           ,@body
-           (buffer-string))
-       (erase-buffer tempbuf)
-       (set-buffer curbuf))))
-
 (defun decode-coding-string (str coding-system)
   "Decode the string STR which is encoded in CODING-SYSTEM.
 Does not modify STR.  Returns the decoded string on successful conversion."