8 trait Recover<Q: ?Sized> {
11 fn get(&self, key: &Q) -> Option<&Self::Key>;
12 fn take(&mut self, key: &Q) -> Option<Self::Key>;
13 fn replace(&mut self, key: Self::Key) -> Option<Self::Key>;
17 pub unsafe fn unwrap_unchecked<T>(val: Option<T>) -> T {
18 val.unwrap_or_else(|| {
19 if cfg!(debug_assertions) {
20 panic!("'unchecked' unwrap on None in BTreeMap");
23 core::intrinsics::unreachable();
31 struct DeterministicRng {
39 impl DeterministicRng {
41 DeterministicRng { x: 0x193a6754, y: 0xa8a7d469, z: 0x97830e05, w: 0x113ba7bb }
44 fn next(&mut self) -> u32 {
46 let t = x ^ (x << 11);
51 self.w = w_ ^ (w_ >> 19) ^ (t ^ (t >> 8));