* edebug-spec of setf: why is the getter evaluated on set?
@ 2022-01-22 11:09 Bruno BARBIER
2022-01-22 21:04 ` Stefan Monnier
0 siblings, 1 reply; 3+ messages in thread
From: Bruno BARBIER @ 2022-01-22 11:09 UTC (permalink / raw)
To: emacs-devel
Hi,
I'm using the gv package (and setf). I really like it.
But, I don't understand why the GETTER is evaluated, when edebugging a
'setf' expression.
For example, let's take that expression:
#+begin_src elisp
(setf my:undefined 7)
#+end_src
and let's assume the symbol "my:undefined" doesn't exist yet (that is,
"not interned").
Evaluating that expression with edebug raises the error:
Symbol's value as variable is void: my:undefined
Evaluating that same expression outside of edebug, just sets the
variable, as expected.
In other words, the debug spec of 'setf' currently is:
(&rest [gv-place form])
shouldn't it be something like:
(&rest [sexp form])
or is it a bug in how 'gv-place' is handled ?
Thanks,
Bruno.
PS: If it matters, I'm using GNU Emacs 27.2
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: edebug-spec of setf: why is the getter evaluated on set?
2022-01-22 11:09 edebug-spec of setf: why is the getter evaluated on set? Bruno BARBIER
@ 2022-01-22 21:04 ` Stefan Monnier
2022-01-22 22:59 ` Bruno Barbier
0 siblings, 1 reply; 3+ messages in thread
From: Stefan Monnier @ 2022-01-22 21:04 UTC (permalink / raw)
To: Bruno BARBIER; +Cc: emacs-devel
> Evaluating that expression with edebug raises the error:
>
> Symbol's value as variable is void: my:undefined
>
> Evaluating that same expression outside of edebug, just sets the
> variable, as expected.
Please report this as a bug.
>
> In other words, the debug spec of 'setf' currently is:
>
> (&rest [gv-place form])
>
> shouldn't it be something like:
>
> (&rest [sexp form])
>
> or is it a bug in how 'gv-place' is handled ?
We'll see,
Stefan
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: edebug-spec of setf: why is the getter evaluated on set?
2022-01-22 21:04 ` Stefan Monnier
@ 2022-01-22 22:59 ` Bruno Barbier
0 siblings, 0 replies; 3+ messages in thread
From: Bruno Barbier @ 2022-01-22 22:59 UTC (permalink / raw)
To: Stefan Monnier; +Cc: emacs-devel
Hi Stefan,
Stefan Monnier <monnier@iro.umontreal.ca> writes:
>> Evaluating that expression with edebug raises the error:
>>
>> Symbol's value as variable is void: my:undefined
>>
>> Evaluating that same expression outside of edebug, just sets the
>> variable, as expected.
>
> Please report this as a bug.
You've already fixed it a while ago ... :-)
It seems it is bug 46573. And, it's not in emacs 27 (my mistake).
Sorry for the noise.
Bruno
>>
>> In other words, the debug spec of 'setf' currently is:
>>
>> (&rest [gv-place form])
>>
>> shouldn't it be something like:
>>
>> (&rest [sexp form])
>>
>> or is it a bug in how 'gv-place' is handled ?
>
> We'll see,
>
>
> Stefan
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-01-22 22:59 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-01-22 11:09 edebug-spec of setf: why is the getter evaluated on set? Bruno BARBIER
2022-01-22 21:04 ` Stefan Monnier
2022-01-22 22:59 ` Bruno Barbier
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).