emacs-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[debbugs-tracker] bug#12293: closed (setf behavior difference)


From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#12293: closed (setf behavior difference)
Date: Tue, 28 Aug 2012 19:38:01 +0000

Your message dated Tue, 28 Aug 2012 15:36:12 -0400
with message-id <address@hidden>
and subject line Re: bug#12293: setf behavior difference
has caused the debbugs.gnu.org bug report #12293,
regarding setf behavior difference
to be marked as done.

(If you believe you have received this mail in error, please contact
address@hidden)


-- 
12293: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=12293
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: setf behavior difference Date: Tue, 28 Aug 2012 09:47:11 -0400 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux)
setf behaves differently in 24.1 vs current trunk.

Save this in test.el:

(require 'cl)

(defvar my-string "
TEST
TEST")

(defun my-test ()
  (with-temp-buffer
    (insert my-string)
    (goto-char (point-min))
    (while (re-search-forward "\r\n" nil t)
      (replace-match "\n" nil nil nil 1))
    (setf (buffer-string) (buffer-string))
    (princ (buffer-string))))

(my-test)


$ /usr/bin/emacs-24.1  --batch -l test.el

TEST
TEST

$ ./emacs --batch -l test.el
$

that is emacs from trunk prints nothing.

The code sequence is derived from bbdb-vcard.el at 
http://github.com/trebb/bbdb-vcard
and the effect is that the package stopped working. 

Searching the web for "(setf (buffer-string)" there are hits in a few
other packages.
It's a rather odd thing to do, but it looks like people are doing it...



--- End Message ---
--- Begin Message --- Subject: Re: bug#12293: setf behavior difference Date: Tue, 28 Aug 2012 15:36:12 -0400 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux)
>     (setf (buffer-string) (buffer-string))

Oops, indeed.  Should be fixed now, thanks for catching it,


        Stefan


--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]