From: Lars Ingebrigtsen <larsi@gnus.org>
To: Okamsn <okamsn@protonmail.com>
Cc: 50290@debbugs.gnu.org
Subject: bug#50290: Using `setf` on `map-elt` repeats evaluation for returning the value of `setf`
Date: Wed, 01 Sep 2021 10:33:10 +0200 [thread overview]
Message-ID: <8735qohf09.fsf@gnus.org> (raw)
In-Reply-To: <2cb39382-4974-9d9e-8e9a-b222f51fa18c@protonmail.com> (okamsn@protonmail.com's message of "Tue, 31 Aug 2021 02:58:11 +0000")
Okamsn <okamsn@protonmail.com> writes:
> When I do `(setf (map-elt map key) (my-func))`, it expands to
>
> (let* ((key key))
> (condition-case nil
> (with-no-warnings
> (map-put! map key (my-func) nil))
> (map-not-inplace
> (setq map (map-insert map key (my-func)))
> (my-func))))
>
> The repetition of `(my-func)` raises warnings.
Yup. This should now be fixed on the trunk.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
prev parent reply other threads:[~2021-09-01 8:33 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-31 2:58 bug#50290: Using `setf` on `map-elt` repeats evaluation for returning the value of `setf` Okamsn via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-09-01 8:33 ` Lars Ingebrigtsen [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8735qohf09.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=50290@debbugs.gnu.org \
--cc=okamsn@protonmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.