MCPcopy Create free account
hub / github.com/dgrunwald/rust-cpython / is_callable

Method is_callable

src/objectprotocol.rs:198–200  ·  view source on GitHub ↗
(&self, _py: Python)

Source from the content-addressed store, hash-verified

196 /// Determines whether this object is callable.
197 #[inline]
198 fn is_callable(&self, _py: Python) -> bool {
199 unsafe { ffi::PyCallable_Check(self.as_ptr()) != 0 }
200 }
201
202 /// Calls the object.
203 /// This is equivalent to the Python expression: 'self(*args, **kwargs)'

Callers

nothing calls this directly

Implementers 1

objectprotocol.rssrc/objectprotocol.rs

Calls 1

as_ptrMethod · 0.45

Tested by

no test coverage detected