cpp/thread/thread

The class represents a single thread of execution. Threads allow multiple functions to execute concurrently.

Threads begin execution immediately upon construction of the associated thread object (pending any OS scheduling delays), starting at the top-level function provided as a constructor argument. The return value of the top-level function is ignored and if it terminates by throwing an exception, std is called. The top-level function may communicate its return value or an exception to the caller via std or by modifying shared variables (which may require synchronization, see std and std)

objects may also be in the state that does not represent any thread (after default construction, move from, detach, or join), and a thread of execution may not be associated with any objects (after detach).

No two objects may represent the same thread of execution;  is not  or, although it is  and.