Expand description
go-spawn
is a library that provides macros to spawn and join threads with minimal boilerplate.
Modules§
Macros§
- go
- Spawns a thread to execute the given code. Any captured variables will be moved to the spawned thread.
- go_ref
- Spawns a thread to execute the given code. Any captured variables will be borrowed by the spawned thread.
- join
- Joins the most recent not-yet-joined thread spawned from the current thread by either
go!
orgo_ref!
. - join_
all - Joins all pending threads spawned from the current thread by either
go!
orgo_ref!
.