Rewrapped comments in tooter.rs.

This commit is contained in:
Aaron Weiss 2018-05-27 23:24:37 +02:00
parent a23f3417f1
commit d4283f6071
No known key found for this signature in database
GPG key ID: 047D32DF25DC22EF

View file

@ -25,15 +25,15 @@ fn main() {
let send_client = client.clone(); let send_client = client.clone();
// Rather than spawn a thread that reads the messages separately, we register a handler with the // Rather than spawn a thread that reads the messages separately, we register a handler with the
// reactor. just as in the original version, we don't do any real handling and instead just print // reactor. just as in the original version, we don't do any real handling and instead just
// the messages that are received. // print the messages that are received.
reactor.register_client_with_handler(client, |_, message| { reactor.register_client_with_handler(client, |_, message| {
print!("{}", message); print!("{}", message);
Ok(()) Ok(())
}); });
// We construct an interval using a wheel timer from tokio_timer. This interval will fire // We construct an interval using a wheel timer from tokio_timer. This interval will fire every
// every 10 seconds (and is roughly accurate to the second). // ten seconds (and is roughly accurate to the second).
let send_interval = tokio_timer::wheel() let send_interval = tokio_timer::wheel()
.tick_duration(Duration::from_secs(1)) .tick_duration(Duration::from_secs(1))
.num_slots(256) .num_slots(256)