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

Method is_empty

publication/code/chapter06/hashmap.rs:36–46  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

34 }
35
36 fn is_empty(&self) -> bool {
37 let mut empty = true;
38 for &d in self.slot.iter() {
39 if 0 != d {
40 empty = false;
41 break;
42 }
43 }
44
45 empty
46 }
47
48 fn clear(&mut self) {
49 let mut slot = Vec::with_capacity(self.cap);

Callers 1

interpolation_searchFunction · 0.45

Calls 1

iterMethod · 0.45

Tested by

no test coverage detected