Add storage to test types, to trigger dtor call.
This commit is contained in:
parent
a3f236fe36
commit
4fef27091e
@ -78,6 +78,7 @@ V // CHECK-NEXT: (cling::Value &) boxes [(int [2][3][4]) { { { 1, 2, 3, 4 }, { 1
|
||||
// Check lifetime of objects in Value
|
||||
.rawInput 1
|
||||
struct WithDtor {
|
||||
char mem = 0;
|
||||
static int fgCount;
|
||||
WithDtor() { ++fgCount; }
|
||||
WithDtor(const WithDtor&) { ++fgCount; }
|
||||
|
@ -14,7 +14,7 @@
|
||||
extern "C" int printf(const char*,...);
|
||||
|
||||
class A {
|
||||
int m_A[2];
|
||||
int m_A[2] = 0;
|
||||
public:
|
||||
A() {}
|
||||
~A() { printf("A::~A()\n"); }
|
||||
@ -43,6 +43,7 @@ public:
|
||||
int gTest = 0;
|
||||
|
||||
class E {
|
||||
char mem = 0;
|
||||
public:
|
||||
~E() { gTest = 101; }
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user