std::thread and class constructor and destructor
- by toeplitz
When testing threads in C++11 I have created the following example:
#include <iostream>
#include <thread>
class Foo {
public:
Foo(void) {
std::cout << "Constructor called: " << this << std::endl;
}
~Foo(void) {
std::cout << "Destructor called: " << this << std::endl;
…