pub fn insert(&self, pid: process::Id) {
        let mut q = self.q.lock();

        // Don't insert duplicates.
        if !q.iter().any(|&x| x == pid) {
            q.push_back(pid);
        }
    }
/// Insert a process to be awakened on this wait queue.
///
/// The process should be in a suitable state to be woken up.
Insert a process to be awakened on this wait queue.
The process should be in a suitable state to be woken up.
Insert a process to be awakened on this wait queue . The process should be in a suitable state to be woken up .
pub fn insert(&self, pid: process::Id) {
        let mut q = self.q.lock();
        // Don't insert duplicates.
        if !q.iter().any(|&x| x == pid) {
            q.push_back(pid);
        }
    }
pub fn insert ( & self , pid : process :: Id ) { let mut q = self . q . lock ( ) ; // Don't insert duplicates. if ! q . iter ( ) . any ( | & x | x == pid ) { q . push_back ( pid ) ; } }
Insert a process to be awakened on this wait queue.
Insert a process to be awakened on this wait queue .
&self
pid
process::Id