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

Method popleft

crates/vm/src/stdlib/_collections.rs:225–230  ·  view source on GitHub ↗
(&self, vm: &VirtualMachine)

Source from the content-addressed store, hash-verified

223
224 #[pymethod]
225 fn popleft(&self, vm: &VirtualMachine) -> PyResult {
226 self.state.fetch_add(1);
227 self.borrow_deque_mut()
228 .pop_front()
229 .ok_or_else(|| vm.new_index_error("pop from an empty deque"))
230 }
231
232 #[pymethod]
233 fn remove(&self, obj: PyObjectRef, vm: &VirtualMachine) -> PyResult {

Callers 15

walkFunction · 0.80
docclassMethod · 0.80
docclassMethod · 0.80
pop_sourceMethod · 0.80
get_tokenMethod · 0.80
_getMethod · 0.80
getMethod · 0.80
_write_sendMethod · 0.80
_sendto_readyMethod · 0.80
_getMethod · 0.80
_wakeup_nextMethod · 0.80

Calls 3

ok_or_elseMethod · 0.80
pop_frontMethod · 0.80
borrow_deque_mutMethod · 0.80

Tested by 6

test_basicsMethod · 0.64
test_comparisonsMethod · 0.64
test_getitemMethod · 0.64
test_lenMethod · 0.64
test_basicsMethod · 0.64
fMethod · 0.64