4
440gtx
I have a class that maintains a static std::list of its instances.
Thus, due to the order of constructors ambiguity of itself and
std::list, it cannot be safely instantiated until after main is
called. What I would like to do is put in an assert if it is
instantiated too early, but unsure how to detect this case. Or perhaps
there is a better design for instance tracking?
Thus, due to the order of constructors ambiguity of itself and
std::list, it cannot be safely instantiated until after main is
called. What I would like to do is put in an assert if it is
instantiated too early, but unsure how to detect this case. Or perhaps
there is a better design for instance tracking?