this is thread number
this is thread number
this is thread number
this is thread number
this is thread number
thread '<main>' panicked at 'called `Result::unwrap()` on an `Err` value: Error { repr: Os { code: 11, message: "Resource temporarily unavailable" } }', src/libcore/result.rs:746
note: Run with `RUST_BACKTRACE=1` for a backtrace.
...
no errors. runs stable, consumes all cores, no feeling of overloading the system.
code:
static NTHREADS: i32 = 100000;
// This is the `main` thread
fn
import "fmt"
func main()
// Make a vector to hold the children which are spawned.
let mut children = vec![];
for i in 0..NTHREADS
children.push(thread::spawn(move || {
println!("this
for i := 0; i < nthreads; i++ {
go func(i int) {
fmt.Printf("this is thread number
}));
}
for child in children {
// Wait for the thread to finish. Returns a result.
let _ = child.join();
}(i)
}
}
dict.cc:
rust: Rost {m}