@@ -139,10 +139,10 @@ impl<S, SinkItem> Compat01As03Sink<S, SinkItem> {
139
139
140
140
fn in_notify < R > (
141
141
& mut self ,
142
- lw : & LocalWaker ,
142
+ waker : & Waker ,
143
143
f : impl FnOnce ( & mut S ) -> R ,
144
144
) -> R {
145
- let notify = & WakerToHandle ( lw . as_waker ( ) ) ;
145
+ let notify = & WakerToHandle ( waker ) ;
146
146
self . inner . poll_fn_notify ( notify, 0 , f)
147
147
}
148
148
}
@@ -155,9 +155,9 @@ where
155
155
156
156
fn poll_next (
157
157
mut self : Pin < & mut Self > ,
158
- lw : & LocalWaker ,
158
+ waker : & Waker ,
159
159
) -> task03:: Poll < Option < Self :: Item > > {
160
- match self . in_notify ( lw , |f| f. poll ( ) ) {
160
+ match self . in_notify ( waker , |f| f. poll ( ) ) {
161
161
Ok ( Async01 :: Ready ( Some ( t) ) ) => task03:: Poll :: Ready ( Some ( Ok ( t) ) ) ,
162
162
Ok ( Async01 :: Ready ( None ) ) => task03:: Poll :: Ready ( None ) ,
163
163
Ok ( Async01 :: NotReady ) => task03:: Poll :: Pending ,
@@ -184,10 +184,10 @@ where
184
184
185
185
fn poll_ready (
186
186
mut self : Pin < & mut Self > ,
187
- lw : & LocalWaker ,
187
+ waker : & Waker ,
188
188
) -> task03:: Poll < Result < ( ) , Self :: SinkError > > {
189
189
match self . buffer . take ( ) {
190
- Some ( item) => match self . in_notify ( lw , |f| f. start_send ( item) ) {
190
+ Some ( item) => match self . in_notify ( waker , |f| f. start_send ( item) ) {
191
191
Ok ( AsyncSink01 :: Ready ) => task03:: Poll :: Ready ( Ok ( ( ) ) ) ,
192
192
Ok ( AsyncSink01 :: NotReady ( i) ) => {
193
193
self . buffer = Some ( i) ;
@@ -201,10 +201,10 @@ where
201
201
202
202
fn poll_flush (
203
203
mut self : Pin < & mut Self > ,
204
- lw : & LocalWaker ,
204
+ waker : & Waker ,
205
205
) -> task03:: Poll < Result < ( ) , Self :: SinkError > > {
206
206
let item = self . buffer . take ( ) ;
207
- match self . in_notify ( lw , |f| match item {
207
+ match self . in_notify ( waker , |f| match item {
208
208
Some ( i) => match f. start_send ( i) {
209
209
Ok ( AsyncSink01 :: Ready ) => f. poll_complete ( ) . map ( |i| ( i, None ) ) ,
210
210
Ok ( AsyncSink01 :: NotReady ( t) ) => {
@@ -225,12 +225,12 @@ where
225
225
226
226
fn poll_close (
227
227
mut self : Pin < & mut Self > ,
228
- lw : & LocalWaker ,
228
+ waker : & Waker ,
229
229
) -> task03:: Poll < Result < ( ) , Self :: SinkError > > {
230
230
let item = self . buffer . take ( ) ;
231
231
let close_started = self . close_started ;
232
232
233
- let result = self . in_notify ( lw , |f| {
233
+ let result = self . in_notify ( waker , |f| {
234
234
if !close_started {
235
235
if let Some ( item) = item {
236
236
if let AsyncSink01 :: NotReady ( item) = f. start_send ( item) ? {
0 commit comments