MCPcopy Index your code
hub / github.com/RustPython/RustPython / Foo

Class Foo

Lib/test/test_rlcompleter.py:111–118  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

109 # class attribute 'bar'. This forces `getattr` to call __getattr__
110 # (which is doesn't necessarily do).
111 class Foo:
112 calls = 0
113 bar = ''
114 def __getattribute__(self, name):
115 if name == 'bar':
116 self.calls += 1
117 return None
118 return super().__getattribute__(name)
119
120 f = Foo()
121 completer = rlcompleter.Completer(dict(f=f))

Callers 3

test_uncreated_attrMethod · 0.70

Calls

no outgoing calls

Tested by 3

test_uncreated_attrMethod · 0.56