Debian Codegraph @

src/test/01-Basic/240-dtor-basic.ck

raw
1 // verify destructo is called
2
3 class Foo
4 {
5 // destructor
6 fun @destruct()
7 {
8 <<< "destructor called...", "" >>>;
9 }
10 }
11
12 // instance
13 Foo foo;
14
15 // destructor should be called when foo goes out of scope