Update main.rs

pull/888/head
qwer252 6 days ago committed by GitHub
parent a621cdf1cb
commit 2803bd0724
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -47,11 +47,11 @@ fn get_messages() -> impl Stream<Item = String> {
fn get_intervals() -> impl Stream<Item = u32> {
let (tx, rx) = trpl::channel();
// 这里 *不是* `trpl::spawn` ,是 `std::thread::spawn`
// 这里 *不是* `trpl::spawn`,是 `std::thread::spawn`
thread::spawn(move || {
let mut count = 0;
loop {
// 同样,这里 *不是* `trpl::sleep` ,是 `std::thread::sleep`
// 同样,这里 *不是* `trpl::sleep`,是 `std::thread::sleep`
thread::sleep(Duration::from_millis(1));
count += 1;

Loading…
Cancel
Save