Eigenpoll : D wish list : solve interdepend static this 

Interdepend static this is now error at execution.
This suggestion introduce lazy import and solve problem (call static this before this module) like:

//a.d
module a;
lazy import b;
class A{
static d_time time;
static this(){
time = B.time /* + 09:00*/;
}
}

//b.d
module b;
import a;
class B{
static d_time time;
static this(){
time = currentTime();
}
static d_time getTime(){
return B.time;
}
}

//flow
a.A.static this();
b.B.static this();

This have problem yet when a.d imported modules and it depended b.d. But this is needed.

Report this item for cleanup