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

Function contains_wrapper

crates/vm/src/types/slot.rs:340–347  ·  view source on GitHub ↗
(
    obj: &PyObject,
    needle: &PyObject,
    vm: &VirtualMachine,
)

Source from the content-addressed store, hash-verified

338}
339
340pub(crate) fn contains_wrapper(
341 obj: &PyObject,
342 needle: &PyObject,
343 vm: &VirtualMachine,
344) -> PyResult<bool> {
345 let ret = vm.call_special_method(obj, identifier!(vm, __contains__), (needle,))?;
346 ret.try_to_bool(vm)
347}
348
349macro_rules! number_unary_op_wrapper {
350 ($name:ident) => {

Callers 1

Calls 2

call_special_methodMethod · 0.80
try_to_boolMethod · 0.80

Tested by

no test coverage detected