For completeness, here is how the destructor for a `ref object` subtype would be coded: type ARef = ref object of RootRef aname: string proc `=destroy`(x: typeof ARef()[]) = `=destroy`(x.aname) type BRef = ref object of ARef bname: string proc `=destroy`(x: typeof BRef()[]) = `=destroy`(x.bname) `=destroy`((typeof ARef()[])(x)) # This is how the base type's destructor is called Run
- Destructors for "ref object" types? lou15b
- Destructors for "ref object" types? enthus1ast
- Destructors for "ref object" types? SolitudeSF
- Destructors for "ref object" types? lou15b
- Destructors for "ref object" types? lou15b