We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8d8a8b6 commit 3175751Copy full SHA for 3175751
src/concurrency/async-control-flow/channels.rs
@@ -1,7 +1,7 @@
1
-use tokio::sync::mpsc::{self, Receiver};
+use tokio::sync::mpsc;
2
3
-async fn ping_handler(mut input: Receiver<()>) {
4
- let mut count: usize = 0;
+async fn ping_handler(mut input: mpsc::Receiver<()>) {
+ let mut count = 0;
5
6
while let Some(_) = input.recv().await {
7
count += 1;
0 commit comments