GNU bug report logs - #37283
27.0.50; Struct defined by cl-defstruct with :noinline failed to set slot using setf

Previous Next

Package: emacs;

Reported by: Zhu Zihao <all_but_last <at> 163.com>

Date: Mon, 2 Sep 2019 15:28:02 UTC

Severity: normal

Found in version 27.0.50

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


Message #11 received at 37283 <at> debbugs.gnu.org (full text, mbox):

From: Zhu Zihao <all_but_last <at> 163.com>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: 37283 <at> debbugs.gnu.org, Zhu Zihao <all_but_last <at> 163.com>
Subject: Re: bug#37283: 27.0.50;
 Struct defined by cl-defstruct with :noinline failed to set slot
 using setf
Date: Mon, 09 Sep 2019 21:26:38 +0800
On Mon, 09 Sep 2019 06:43:15 +0800,
Stefan Monnier wrote:
> 
> > (require 'cl-lib)
> > (cl-defstruct (stt (:noinline t))
> >   slt-a slt-b)
> >
> > (let ((inst (make-stt :slt-a 1 :slt-b 2)))
> >   (setf (stt-slt-a inst) 2))
> >
> > Will get error "Symbol’s function definition is void: \(setf\ stt-slt-a\)"
> 
> I just push a patch to `master` which should fix this problem.
> Can you confirm it fixes it on your side as well?
> 
> 
>         Stefan

Yes, this snippet work as expected now. Thanks for your work.





This bug report was last modified 5 years and 255 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.