3 ms·
Thanks. My question emerged from the fact that all the Rust threads examples I see are in the closure form || {}.
by scoutt 6y ago
Thanks. My question emerged from the fact that all the Rust threads examples I see are in the closure form || {}.
- zesterer 6y agoBecause the closure form is much more useful. You very rarely want to create a thread without first passing some state to it, and environment-passing with closures is a brilliantly ergonomic way to do this.