.
This commit is contained in:
parent
672289a9cf
commit
798006c8d0
4
main.cpp
4
main.cpp
@ -7,7 +7,7 @@ public:
|
|||||||
A() {
|
A() {
|
||||||
std::cout << "Class A Created\n";
|
std::cout << "Class A Created\n";
|
||||||
}
|
}
|
||||||
~A() {
|
virtual ~A() {
|
||||||
std::cout << "Class A Destroyed\n";
|
std::cout << "Class A Destroyed\n";
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@ -28,7 +28,7 @@ public:
|
|||||||
C() {
|
C() {
|
||||||
std::cout << "Class C Created\n";
|
std::cout << "Class C Created\n";
|
||||||
}
|
}
|
||||||
~C() {
|
virtual ~C() {
|
||||||
std::cout << "Class C Destroyed\n";
|
std::cout << "Class C Destroyed\n";
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user