MCPcopy Create free account
hub / github.com/QMHTMY/RustBook / dequeue

Method dequeue

publication/code/chapter08/bst.rs:30–36  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

28 }
29
30 fn dequeue(&mut self) -> Option<T> {
31 if self.len() > 0 {
32 self.data.pop()
33 } else {
34 None
35 }
36 }
37
38 fn is_empty(&self) -> bool {
39 0 == self.len()

Callers 2

levelorderMethod · 0.45
levelorderFunction · 0.45

Calls 2

lenMethod · 0.45
popMethod · 0.45

Tested by

no test coverage detected