Questions tagged [object-destruction]
34 questions
0
votes
4 answers
Can the object be destroyed earlier, to make its storage memory be reused by subsequent objects?
C++: can the object be destroyed earlier, to make its storage memory be reused by subsequent objects?
In one segment of C++ code, at the 1st half part, objects a, b are used;
at the 2nd half part, objects c, d are created and used.
Since objects a,…

user1914692
- 3,033
- 5
- 36
- 61
0
votes
1 answer
Delphi XE3 Invalid Pointer when trying to free FSQL (TStringList)
I'm creating a new app in XE3 but using some units created in D2007.
I"m getting an error when freeing a TStringList data item. Here's the code that creates the data item FSQL:
procedure TPayorDM.DataModuleCreate(Sender: TObject);
begin
FPayorDRM…

Rich R
- 367
- 4
- 15
-1
votes
4 answers
How to empty std::set from objects' pointers?
I am having an issue emptying my set, so I have 3 classes like so:
class A, and 2 inherited classes B and C.
In the code I store elements in my set from the 3 types, the set is:
set objects;
so whenever I create a B element I do that:
A* b =…

ConanCoder
- 39
- 2
- 10
-2
votes
1 answer
How to prevent message handling after the control's destruction
There are two instances of the following component types:
TfrmTimeSliceStructure, which is a direct descendant of TFrame.
THKSDBVirtualStringTree, which is a direct descendant of TDBVirtualStringTree (from FIBPlus), which itself is a direct…

René Hoffmann
- 2,766
- 2
- 20
- 43