www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - food for thought

If you want a class without a root object just use extern(C++).
Also this is apparently legal:
extern (C++) class Root : Object
{
};

int main()
{
     auto root = new Root;
     Object obj = root; // is this safe?
     return 0;
}
Oct 07 2016