MCPcopy Create free account
hub / github.com/Extra-Creativity/Modern-Cpp-Basics / Object

Class Object

13-Multithreading/Answer-code/Thread.cpp:119–136  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

117}
118
119class Object
120{
121public:
122 Object() { std::cout << "Construct at " << this << "\n"; };
123 ~Object() { std::cout << "Destruct at " << this << "\n"; };
124 Object(const Object &) { std::cout << "Const Copy at " << this << "\n"; };
125 Object(Object &&) { std::cout << "Move at " << this << "\n"; };
126 Object &operator=(const Object &)
127 {
128 std::cout << "Const Copy Assignment at " << this << "\n";
129 return *this;
130 };
131 Object &operator=(Object &&)
132 {
133 std::cout << "Move Assignment at " << this << "\n";
134 return *this;
135 };
136};
137
138void foo(Object obj)
139{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected