pub async fn pop(&self) -> T {
        let txn = self.available.sub();
        let permit = self.semaphore.acquire().await.unwrap();
        txn.commit();
        //txn.commit();
        // FIXME must be used
        let item = self.queue.pop().unwrap();
        permit.forget();
        item
    }
/// Get an item from the queue. If the queue is currently empty
/// this method blocks until an item is available.
Get an item from the queue. If the queue is currently empty
this method blocks until an item is available.
Get an item from the queue . If the queue is currently empty this method blocks until an item is available .
pub async fn pop(&self) -> T {
        let txn = self.available.sub();
        let permit = self.semaphore.acquire().await.unwrap();
        txn.commit();
        //txn.commit();
        // FIXME must be used
        let item = self.queue.pop().unwrap();
        permit.forget();
        item
    }
pub async fn pop ( & self ) -> T { let txn = self . available . sub ( ) ; let permit = self . semaphore . acquire ( ) . await . unwrap ( ) ; txn . commit ( ) ; //txn.commit(); // FIXME must be used let item = self . queue . pop ( ) . unwrap ( ) ; permit . forget ( ) ; item }
Get an item from the queue.
Get an item from the queue .
&self
&self