MCPcopy Index your code
hub / github.com/python/cpython / peek

Method peek

Lib/weakref.py:502–508  ·  view source on GitHub ↗

If alive then return (obj, func, args, kwargs); otherwise return None

(self)

Source from the content-addressed store, hash-verified

500 return (obj, info.func, info.args, info.kwargs or {})
501
502 def peek(self):
503 """If alive then return (obj, func, args, kwargs);
504 otherwise return None"""
505 info = self._registry.get(self)
506 obj = info and info.weakref()
507 if obj is not None:
508 return (obj, info.func, info.args, info.kwargs or {})
509
510 @property
511 def alive(self):

Callers

nothing calls this directly

Calls 1

getMethod · 0.45

Tested by

no test coverage detected