summaryrefslogtreecommitdiff
path: root/testsuite/tests/rts/linker/T20494-obj.cpp
blob: d0cc52704a32d24d5b1e90d08f7fad05537eb8b0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include <cstdio>

class A {
public:
    const char *msg;
    A(const char *msg) {
        printf("constr %s\n", msg); 
        this->msg = msg;
    }

    ~A() {
        printf("destroy %s\n", this->msg); 
    }
};

A a("helloA");
A b("helloB");

int main() {
    printf("main\n");
    return 0;
}