You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Preferably this should also take something like &mut self where Self: Unpin to really avoid the issue from the below linked thread, unfortunately making a really useful signature like that would probably require defining an extra extension trait so that a Pin<impl DerefMut<Target = Peekable<_>>> would also be a Peekable.
The current
Peekable::peek
signature doesn't seem right to me when related to other methods:I think this should be renamed to
poll_peek
, and another function added that returns aFuture
resolving to the peeked item:Preferably this should also take something like
&mut self where Self: Unpin
to really avoid the issue from the below linked thread, unfortunately making a really useful signature like that would probably require defining an extra extension trait so that aPin<impl DerefMut<Target = Peekable<_>>>
would also be aPeekable
.(Related to this u.rl.o thread)
The text was updated successfully, but these errors were encountered: