Why should I using std::thread::join and then wait until this thread has ended? I thougt the purpose of multithreading is, that I start more threads paralelly. Instead of join(), I also could call the function "normally", like foo(). So why is their join()? Isn't the only thing I need detach()?
Aucun commentaire:
Enregistrer un commentaire