Home
last modified time | relevance | path

Searched refs:popitem (Results 1 – 25 of 34) sorted by relevance

12

/third_party/python/Lib/test/
Dtest_ordered_dict.py226 self.assertEqual(od.popitem(), pairs.pop())
228 od.popitem()
237 obj.popitem(True)
238 obj.popitem(True)
239 obj.popitem(last=True)
563 od.popitem()
584 od.popitem(last=False)
627 dict.popitem(od)
857 self.assertRaises(KeyError, d.popitem)
869 self.assertRaises(KeyError, d.popitem)
[all …]
Dtest_iterlen.py120 self.mutate = d.popitem
127 self.mutate = d.popitem
134 self.mutate = d.popitem
Dmapping_tests.py35 key, value = self.reference.popitem()
39 key, value = self.reference.popitem()
127 key, value = d.popitem()
131 self.assertRaises(KeyError, p.popitem)
290 self.assertRaises(KeyError, d.popitem)
291 self.assertRaises(TypeError, d.popitem, 42)
516 ka, va = ta = a.popitem()
518 kb, vb = tb = b.popitem()
Dtest_dict_version.py154 self.check_version_changed(d, d.popitem)
158 d.popitem)
Dtest_userdict.py141 self.assertEqual(t.popitem(), ("x", 42))
142 self.assertRaises(KeyError, t.popitem)
Dtest_dict.py473 ka, va = ta = a.popitem()
475 kb, vb = tb = b.popitem()
482 self.assertRaises(KeyError, d.popitem)
1068 item = a.popitem() # split table is combined
1102 a.__dict__.popitem()
1261 d.popitem()
Dtest_weakref.py1484 dict.popitem()
1492 dict.popitem()
1603 k, v = weakdict.popitem()
1609 k, v = weakdict.popitem()
Dtest_configparser.py818 self.assertEqual(cf.popitem()[0], 'section1')
819 self.assertEqual(cf.popitem()[0], 'section2')
820 self.assertEqual(cf.popitem()[0], 'section3')
822 cf.popitem()
Dtest_mailbox.py450 key, msg = self._box.popitem()
503 self._box.popitem()
505 self._box.popitem()
581 self.assertRaises(NotImplementedError, lambda: box.popitem())
Dtest_collections.py178 self.assertEqual(d.popitem(), ('b', 2)) # check popitem() w/missing
180 d.popitem()
2054 elem, cnt = c.popitem()
/third_party/python/Lib/
Dweakref.py253 def popitem(self): member in WeakValueDictionary
257 key, wr = self.data.popitem()
496 def popitem(self): member in WeakKeyDictionary
499 key, value = self.data.popitem()
D_collections_abc.py963 def popitem(self): member in MutableMapping
979 self.popitem()
Dconfigparser.py862 def popitem(self): member in RawConfigParser
Dmailbox.py157 def popitem(self): member in Mailbox
/third_party/protobuf/python/google/protobuf/
Dmessage_factory.py161 _AddFile(file_by_name.popitem()[1])
/third_party/protobuf/python/google/protobuf/internal/
Dcontainers.py137 def popitem(self): member in MutableMapping
149 self.popitem()
Dmessage_test.py2268 key, value = map_int32.popitem()
2275 map_int32.popitem()
/third_party/python/Lib/collections/
D__init__.py158 def popitem(self, last=True): member in OrderedDict
1042 def popitem(self): member in ChainMap
1045 return self.maps[0].popitem()
/third_party/vixl/tools/
Dtest.py339 option, values = kwargs.popitem()
/third_party/python/Doc/library/
Dcollections.rst1095 * The :meth:`popitem` method of :class:`OrderedDict` has a different
1111 .. method:: popitem(last=True)
1113 The :meth:`popitem` method for ordered dictionaries returns and removes a
1200 self.cache.popitem(0)
1232 self.requests.popitem(0)
1237 self.cache.popitem(0)
Dcollections.abc.rst162 … ``__setitem__``, ``pop``, ``popitem``, ``clear``, ``update``,
Dnntplib.rst340 >>> descs.popitem() # doctest: +SKIP
/third_party/python/Lib/zoneinfo/
D_zoneinfo.py50 cls._strong_cache.popitem(last=False)
/third_party/python/Doc/whatsnew/
D2.1.rst736 * A new method, :meth:`popitem`, was added to dictionaries to enable
739 all the keys or values. ``D.popitem()`` removes a random ``(key, value)`` pair
D2.7.rst247 The :meth:`~collections.OrderedDict.popitem` method has an optional *last*
253 >>> od.popitem()
255 >>> od.popitem()
257 >>> od.popitem(last=False)
259 >>> od.popitem(last=False)

12