// Check that all pointers handed out are unique (we don't mess up regular
// allocation)
Check that all pointers handed out are unique (we don't mess up regular
allocation)
Check that all pointers handed out are unique ( we don ' t mess up regular allocation )
fn is_all_disjoint_or_zero(pointers: &Vec<Vec<u64>>) -> bool {
            use std::collections::HashSet;
            let mut set = HashSet::with_capacity(MAX_REPLICAS * ITERATIONS);
            for plist in pointers {
                for ptr in plist {
                    if *ptr == 0x0 {
                        // Skip null ptr
                        continue;
                    }
                    if !set.contains(&ptr) {
                        set.insert(ptr);
                    } else {
                        return false;
                    }
                }
            }
            true
        }
fn is_all_disjoint_or_zero ( pointers : & Vec < Vec < u64 > > ) -> bool { use std :: collections :: HashSet ; let mut set = HashSet :: with_capacity ( MAX_REPLICAS * ITERATIONS ) ; for plist in pointers { for ptr in plist { if * ptr == 0x0 { // Skip null ptr continue ; } if ! set . contains ( & ptr ) { set . insert ( ptr ) ; } else { return false ; } } } true }
Check that all pointers handed out are unique (we don't mess up regular
allocation)
Check that all pointers handed out are unique ( we don ' t mess up regular allocation )
pointers
&Vec<Vec<u64>>