Hi rooters!
Assume I have the following code:
class TAsset : public TFinObject {
..
virtual ~TAsset() { gDataManager->Remove(this); }
virtual Int_t GetType() { return kAsset; }
..
};
class TStock : public TAsset {
..
virtual Int_t GetType() { return kStock; }
..
};
TDataManager::Remove(TAsset *Asset) {
..
cout << Asset->GetType() << endl;
..
};
gDataManager = new TDataManager();
TStock *Stock = new TStock();
delete Stock();
What will be the output in TDataManager::Remove() ? kAsset or kStock?
Regards,
Anton
This archive was generated by hypermail 2b29 : Tue Jan 01 2002 - 17:50:35 MET