async_db "fixme" comments
This commit is contained in:
		@@ -146,6 +146,8 @@ where
 | 
			
		||||
use pin_project::pin_project;
 | 
			
		||||
 | 
			
		||||
#[pin_project]
 | 
			
		||||
/// FIXME: not really async
 | 
			
		||||
/// only work when ..push.poll() returns Ready immediately
 | 
			
		||||
pub struct WriterSink<'a, T>
 | 
			
		||||
where
 | 
			
		||||
    T: bincode::Encode,
 | 
			
		||||
@@ -173,7 +175,7 @@ where
 | 
			
		||||
 | 
			
		||||
        let item = this.item.take().unwrap();
 | 
			
		||||
 | 
			
		||||
        let push_fut = this.writer.push(item);
 | 
			
		||||
        let push_fut = this.writer.push(item); // FIXME:: how to save this future???
 | 
			
		||||
        pin_mut!(push_fut);
 | 
			
		||||
        push_fut.poll(ctx)
 | 
			
		||||
    }
 | 
			
		||||
@@ -333,6 +335,7 @@ where
 | 
			
		||||
            return Poll::Ready(None);
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        // FIXME: mayby work only if reader.get().poll() return Ready immediately
 | 
			
		||||
        let future = self.reader.get(self.index.unwrap());
 | 
			
		||||
        pin_mut!(future);
 | 
			
		||||
        match Pin::new(&mut future).poll(cx) {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user