/third_party/python/Lib/importlib/metadata/ |
H A D | _collections.py | 20 def __missing__(self, key): member in FreezableDefaultDict 21 return getattr(self, '_frozen', super().__missing__)(key)
|
/third_party/python/Lib/test/ |
H A D | test_userdict.py | 168 # Make sure UserDict doesn't have a __missing__ method 169 self.assertEqual(hasattr(collections.UserDict, "__missing__"), False) 171 # (D) subclass defines __missing__ method returning a value 172 # (E) subclass defines __missing__ method raising RuntimeError 173 # (F) subclass sets __missing__ instance variable (no effect) 174 # (G) subclass doesn't define __missing__ at all 176 def __missing__(self, key): member in UserDictTest.test_missing.D 185 def __missing__(self, key): member in UserDictTest.test_missing.E 196 # An instance variable __missing__ should have no effect 197 self.__missing__ [all...] |
H A D | test_defaultdict.py | 54 self.assertRaises(KeyError, d1.__missing__, 42) 56 self.assertEqual(d1.__missing__(42), [])
|
H A D | test_dynamic.py | 140 def __missing__(self, key): member in RebindBuiltinsTests.test_load_global_specialization_failure_keeps_oparg.MyGlobals
|
H A D | test_getpath.py | 909 def __missing__(self, key): member in MockNTNamespace 1086 def __missing__(self, key): member in MockPosixNamespace
|
H A D | test_ordered_dict.py | 256 # make sure pop still works when __missing__ is defined 258 def __missing__(self, key): member in OrderedDictTests.test_pop.Missing 405 # make sure setdefault still works when __missing__ is defined 407 def __missing__(self, key): member in OrderedDictTests.test_setdefault.Missing
|
H A D | test_dict.py | 744 # Make sure dict doesn't have a __missing__ method 745 self.assertFalse(hasattr(dict, "__missing__")) 746 self.assertFalse(hasattr({}, "__missing__")) 748 # (D) subclass defines __missing__ method returning a value 749 # (E) subclass defines __missing__ method raising RuntimeError 750 # (F) subclass sets __missing__ instance variable (no effect) 751 # (G) subclass doesn't define __missing__ at all 753 def __missing__(self, key): member in DictTest.test_missing.D 763 def __missing__(self, key): member in DictTest.test_missing.E 772 # An instance variable __missing__ shoul [all...] |
H A D | test_types.py | 1079 def __missing__(self, key): member in MappingProxyTests.test_missing.dictmissing
|
H A D | test_collections.py | 167 def __missing__(self, key): member in TestChainMap.test_missing.DefaultChainMap
|
H A D | test_unicode.py | 1389 def __missing__(self, key): member in UnicodeTest.test_format_map.Mapping
|
/third_party/python/Lib/email/ |
H A D | _encoded_words.py | 77 def __missing__(self, key): member in _QByteMap
|
/third_party/python/Lib/collections/ |
H A D | __init__.py | 599 def __missing__(self, key): member in Counter 995 def __missing__(self, key): member in ChainMap 1004 return self.__missing__(key) # support subclasses that define __missing__ 1122 if hasattr(self.__class__, "__missing__"): 1123 return self.__class__.__missing__(self, key) 1135 # Modify __contains__ to work correctly when __missing__ is present
|
/third_party/python/Lib/idlelib/ |
H A D | pyparse.py | 114 def __missing__(self, key): member in ParseMap 118 # Map all ascii to 120 to avoid __missing__ call, then replace some.
|
/third_party/python/Include/internal/ |
H A D | pycore_global_strings.h | 146 STRUCT_FOR_ID(__missing__)
|
H A D | pycore_runtime_init.h | 769 INIT_ID(__missing__), \
|
/third_party/python/Lib/urllib/ |
H A D | parse.py | 826 # Keeps a cache internally, via __missing__, for efficiency (lookups 835 def __missing__(self, b): member in _Quoter
|
/third_party/python/Lib/test/test_sqlite3/ |
H A D | test_dbapi.py | 885 def __missing__(self, key): member in CursorTests.test_execute_dict_mapping_mapping.D
|
/third_party/python/Objects/ |
H A D | dictobject.c | 2505 /* Look up __missing__ method if we're a subclass. */ in dict_subscript() 2508 (PyObject *)mp, &_Py_ID(__missing__)); in dict_subscript()
|