making a n instance of an object static

mandymo

New member
making a n instance of an object static

I have an abstract class "BaseClass" and a derived class: "DClass". I have a static variable, named b of type BaseClass* I call to the following function f with an instance of DClass as the paremeter. Is it OK?? void f(BaseClass b) { if (base) delete (base); base = b; }​
 
למעלה