Or even the simplier way. Just do:
extern(C++) struct A {
int x;
A A(int x_);
A A(ref const(A) v);
void ~A(A*);
}
And call those methods manually:
A obj = A.A(1);
A obj1 = A.A(obj);
A.~A(&obj);
A.~A(&obj1);
The problem here it to distinguish real static methods from fake
ones. But we can actually make user mark real static methods as
static.