MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / update

Method update

tools/python-3.11.9-amd64/Lib/weakref.py:289–299  ·  view source on GitHub ↗
(self, other=None, /, **kwargs)

Source from the content-addressed store, hash-verified

287 return o
288
289 def update(self, other=None, /, **kwargs):
290 if self._pending_removals:
291 self._commit_removals()
292 d = self.data
293 if other is not None:
294 if not hasattr(other, "items"):
295 other = dict(other)
296 for key, o in other.items():
297 d[key] = KeyedRef(o, self._remove, key)
298 for key, o in kwargs.items():
299 d[key] = KeyedRef(o, self._remove, key)
300
301 def valuerefs(self):
302 """Return a list of weak references to the values.

Callers 2

__init__Method · 0.95
__ior__Method · 0.95

Calls 3

_commit_removalsMethod · 0.95
KeyedRefClass · 0.85
itemsMethod · 0.45

Tested by

no test coverage detected