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

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

bug#24270: Seeming bug in `setf'


From: Rafael D Sorkin
Subject: bug#24270: Seeming bug in `setf'
Date: Sun, 21 Aug 2016 20:34:47 -0400

Hello Michael and Nico,

The maintainer here says that emacs 25 is not yet officially
released.  He has asked me to ask you which version has the
bug fixed:

  "Please inquire which version has the error corrected; we can
  then install them.  If this requires installing a non-relased
  version, this will be fine as well, but we then won't make it
  the default setting for new users."

Is there a released version in which the bug has been fixed?
Can you advise me which version would be best for him to install? 

Many thanks,
Rafael

> Hello Rafael,
>
> > (emacs-version) ; GNU Emacs 24.3.1 (x86_64-pc-linux-gnu, GTK+ Version
> > 3.10.7) of 2014-03-07 on lamiak, modified by Debian
> >
> > (setq z ())
> > (getf z 'indic) ; nil
> > (setf (getf z 'indic) 6) ; (indic 6) SHOULD BE JUST 6
> > (getf z 'indic) ; 6 okay
>
> Thanks for reporting. Yes, there was such a bug, but your Emacs version
> is very old...and the bug has been fixed in the meantime (three years
> ago) in
>
>
> c46c57b, Stefan Monnier <address@hidden>
>
> * lisp/emacs-lisp/cl-extra.el (cl-getf): Return the proper value in
> the setter.
>
> Fixes: debbugs:14387
>
>
> modified lisp/emacs-lisp/cl-extra.el
> @@ -597,8 +597,11 @@ cl-getf
> (macroexp-let2 nil d def
> (funcall do `(cl-getf ,getter ,k ,d)
> (lambda (v)
> - (funcall setter
> - `(cl--set-getf ,getter ,k ,v))))))))))
> + (macroexp-let2 nil val v
> + `(progn
> + ,(funcall setter
> + `(cl--set-getf ,getter ,k ,val))
> + ,val))))))))))
> (setplist '--cl-getf-symbol-- plist)
> (or (get '--cl-getf-symbol-- tag)
> ;; Originally we called cl-get here,
> modified lisp/emacs-lisp/cl-loaddefs.el
>
>
> Regards,
>
> Michael.


> Hi Rafael,
>
> Thank you for reporting this issue.
>
> > The macro `setf' seems to have developed a bug somewhere between emacs
23.1.1 and 24.3.1:
> >
> > (emacs-version) ; GNU Emacs 24.3.1 (x86_64-pc-linux-gnu, GTK+ Version
3.10.7) of 2014-03-07 on lamiak, modified by Debian
> >
> > (setq z ())
> > (getf z 'indic) ; nil
> > (setf (getf z 'indic) 6) ; (indic 6) SHOULD BE JUST 6
> > (getf z 'indic) ; 6 okay
>
> It seems to have been fixed in master & Emacs 25.1 RC1, so I'm closing the
> issue.
>
> However, if you can still reproduce it in master (I couldn't, but who
> knows), feel free to reopen it.
>
> Cheers,
> Nico





~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
 Rafael Sorkin
 Perimeter Institute for Theoretical Physics
 31 Caroline Street North
 Waterloo, ON  N2L 2Y5
 Canada
~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
 A story-poem by Mark Twain -- http://warprayer.org/
~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-





reply via email to

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