unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#25929: 25.2; map-delete doesn't delete permanently 1st alist elt
@ 2017-03-02  7:17 Tino Calancha
  2017-03-02  8:56 ` Nicolas Petton
                   ` (2 more replies)
  0 siblings, 3 replies; 32+ messages in thread
From: Tino Calancha @ 2017-03-02  7:17 UTC (permalink / raw)
  To: 25929; +Cc: nicolas, tino.calancha


X-Debbugs-CC: <nicolas@petton.fr>

(cl-loop for i below 3 collect
  (let ((map (list (cons 0 3)
                   (cons 1 4)
                   (cons 2 5))))
    (map-delete map i)
    (null (map-elt map i))))
=> (nil t t) ; The first pair, i.e. '(0 . 3) is not permanently deleted.

I've used the word 'permantly' because it seems it is temporary
deleted:

(cl-loop for i below 3 collect
  (let ((map (list (cons 0 3)
                   (cons 1 4)
                   (cons 2 5))))
    (null (map-elt
           (map-delete map i)
           i))))
=> (t t t)

*) It happens just for alist, other maps are fine.
*) The test suite doesn't detect this issue because `test-map-delete'
   happen to delete just the 2rd element of the maps.

In GNU Emacs 25.2.3 (x86_64-pc-linux-gnu, GTK+ Version 3.22.7)
 of 2017-03-02
Repository revision: 640661838dbba8185990e839712c91a14641ddf3





^ permalink raw reply	[flat|nested] 32+ messages in thread

end of thread, other threads:[~2022-04-28 16:00 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-02  7:17 bug#25929: 25.2; map-delete doesn't delete permanently 1st alist elt Tino Calancha
2017-03-02  8:56 ` Nicolas Petton
2017-03-02 10:59 ` Nicolas Petton
2017-03-02 11:30   ` Tino Calancha
2017-03-02 12:27     ` Nicolas Petton
2017-03-02 12:34   ` Nicolas Petton
2017-03-02 13:34     ` Tino Calancha
2017-03-02 15:12     ` Stefan Monnier
2017-03-04  0:04       ` Michael Heerdegen
2017-03-04  0:16         ` Michael Heerdegen
2017-03-21 20:41         ` Lars Ingebrigtsen
2017-03-22 11:55           ` Michael Heerdegen
2017-03-22 12:01             ` Lars Ingebrigtsen
2017-03-22 12:56               ` Noam Postavsky
2017-03-22 13:31                 ` Lars Ingebrigtsen
2017-03-22 14:43                   ` Michael Heerdegen
2017-03-22 17:04                   ` Stefan Monnier
2017-03-22 17:23                     ` Lars Ingebrigtsen
2017-03-22 20:31                       ` Stefan Monnier
2017-03-22 17:02               ` Stefan Monnier
2017-03-29 15:25             ` bug#25929: 25.2; plists and map-* Lars Ingebrigtsen
2017-03-29 15:36               ` Nicolas Petton
2017-03-21 11:35       ` bug#25929: 25.2; map-delete doesn't delete permanently 1st alist elt Nicolas Petton
2017-03-21 15:11         ` Stefan Monnier
2017-03-21 18:06           ` Nicolas Petton
2017-03-21 20:29             ` Stefan Monnier
2017-04-26  7:58               ` Nicolas Petton
2017-03-02 12:36   ` npostavs
2017-03-02 12:45     ` Nicolas Petton
2022-04-26 13:34 ` Lars Ingebrigtsen
2022-04-28  3:17   ` Richard Stallman
2022-04-28 16:00     ` Drew Adams

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).