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

Method discard

crates/vm/src/builtins/set.rs:333–335  ·  view source on GitHub ↗
(&self, item: &PyObject, vm: &VirtualMachine)

Source from the content-addressed store, hash-verified

331 }
332
333 fn discard(&self, item: &PyObject, vm: &VirtualMachine) -> PyResult<bool> {
334 self.retry_op_with_frozenset(item, vm, |item, vm| self.content.delete_if_exists(vm, item))
335 }
336
337 fn clear(&self) {
338 self.content.clear()

Callers

nothing calls this directly

Calls 3

delete_if_existsMethod · 0.80
mapMethod · 0.45

Tested by

no test coverage detected