all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#38375: 26.3.50; map-contains-key can't detect nil
@ 2019-11-25 17:15 Damien Cassou
  2019-11-25 23:22 ` Juanma Barranquero
  2019-11-25 23:34 ` Michael Heerdegen
  0 siblings, 2 replies; 5+ messages in thread
From: Damien Cassou @ 2019-11-25 17:15 UTC (permalink / raw)
  To: 38375; +Cc: Nicolas Petton

The code below inserts the pair (nil, 'value) in a hash table. I expect
`map-contains-key' to return t when passed the key nil as argument.

(ert-deftest test-map-contains-key-with-nil-has-key-in-hashtable ()
  (let ((map (make-hash-table :test 'equal)))
    (puthash nil 'value map)
    (should (map-contains-key map nil))))

-- 
Damien Cassou

"Success is the ability to go from one failure to another without
losing enthusiasm." --Winston Churchill





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

end of thread, other threads:[~2019-11-26 15:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-11-25 17:15 bug#38375: 26.3.50; map-contains-key can't detect nil Damien Cassou
2019-11-25 23:22 ` Juanma Barranquero
2019-11-25 23:34 ` Michael Heerdegen
2019-11-26 15:12   ` Damien Cassou
2019-11-26 15:44     ` Michael Heerdegen

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.