@@ -96,10 +96,10 @@ mod if_std {
96
96
97
97
/// Attempt to read from the `AsyncRead` into `buf`.
98
98
///
99
- /// On success, returns `Ok( Poll::Ready(num_bytes_read))`.
99
+ /// On success, returns `Poll::Ready(Ok (num_bytes_read))`.
100
100
///
101
101
/// If no data is available for reading, the method returns
102
- /// `Ok( Poll::Pending) ` and arranges for the current task (via
102
+ /// `Poll::Pending` and arranges for the current task (via
103
103
/// `cx.waker().wake_by_ref()`) to receive a notification when the object becomes
104
104
/// readable or is closed.
105
105
///
@@ -118,10 +118,10 @@ mod if_std {
118
118
/// This method is similar to `poll_read`, but allows data to be read
119
119
/// into multiple buffers using a single operation.
120
120
///
121
- /// On success, returns `Ok( Poll::Ready(num_bytes_read))`.
121
+ /// On success, returns `Poll::Ready(Ok (num_bytes_read))`.
122
122
///
123
123
/// If no data is available for reading, the method returns
124
- /// `Ok( Poll::Pending) ` and arranges for the current task (via
124
+ /// `Poll::Pending` and arranges for the current task (via
125
125
/// `cx.waker().wake_by_ref()`) to receive a notification when the object becomes
126
126
/// readable or is closed.
127
127
/// By default, this method delegates to using `poll_read` on the first
@@ -156,10 +156,10 @@ mod if_std {
156
156
pub trait AsyncWrite {
157
157
/// Attempt to write bytes from `buf` into the object.
158
158
///
159
- /// On success, returns `Ok( Poll::Ready(num_bytes_written))`.
159
+ /// On success, returns `Poll::Ready(Ok (num_bytes_written))`.
160
160
///
161
161
/// If the object is not ready for writing, the method returns
162
- /// `Ok( Poll::Pending) ` and arranges for the current task (via
162
+ /// `Poll::Pending` and arranges for the current task (via
163
163
/// `cx.waker().wake_by_ref()`) to receive a notification when the object becomes
164
164
/// readable or is closed.
165
165
///
@@ -178,10 +178,10 @@ mod if_std {
178
178
/// This method is similar to `poll_write`, but allows data from multiple buffers to be written
179
179
/// using a single operation.
180
180
///
181
- /// On success, returns `Ok( Poll::Ready(num_bytes_written))`.
181
+ /// On success, returns `Poll::Ready(Ok (num_bytes_written))`.
182
182
///
183
183
/// If the object is not ready for writing, the method returns
184
- /// `Ok( Poll::Pending) ` and arranges for the current task (via
184
+ /// `Poll::Pending` and arranges for the current task (via
185
185
/// `cx.waker().wake_by_ref()`) to receive a notification when the object becomes
186
186
/// readable or is closed.
187
187
///
@@ -209,10 +209,10 @@ mod if_std {
209
209
/// Attempt to flush the object, ensuring that any buffered data reach
210
210
/// their destination.
211
211
///
212
- /// On success, returns `Ok( Poll::Ready(()))`.
212
+ /// On success, returns `Poll::Ready(Ok (()))`.
213
213
///
214
214
/// If flushing cannot immediately complete, this method returns
215
- /// `Ok( Poll::Pending) ` and arranges for the current task (via
215
+ /// `Poll::Pending` and arranges for the current task (via
216
216
/// `cx.waker().wake_by_ref()`) to receive a notification when the object can make
217
217
/// progress towards flushing.
218
218
///
@@ -226,10 +226,10 @@ mod if_std {
226
226
227
227
/// Attempt to close the object.
228
228
///
229
- /// On success, returns `Ok( Poll::Ready(()))`.
229
+ /// On success, returns `Poll::Ready(Ok (()))`.
230
230
///
231
231
/// If closing cannot immediately complete, this function returns
232
- /// `Ok( Poll::Pending) ` and arranges for the current task (via
232
+ /// `Poll::Pending` and arranges for the current task (via
233
233
/// `cx.waker().wake_by_ref()`) to receive a notification when the object can make
234
234
/// progress towards closing.
235
235
///
0 commit comments