Search found 2 matches

by palatini
Wed 02 Feb 2022 00:40
Forum: MySQL Data Access Components
Topic: Free vs Delete
Replies: 2
Views: 16897

Re: Free vs Delete

Emailed the above question to support and got this response.

According to the Embarcadero documentation, the Delete method is recommended to be used in the C++ projects.
by palatini
Thu 27 Jan 2022 02:38
Forum: MySQL Data Access Components
Topic: Free vs Delete
Replies: 2
Views: 16897

Free vs Delete

on the demos we have example code

{
TMyQuery* q = new TMyQuery(NULL);
try
{
...
}
__finally
{
q->Free();
}
}

TMyConnection* MyConnection1 = new TMyConnection(NULL);
try {
....
}
__finally {
MyConnection1->Free();
}


I would like to know why the examples use q->Free(); instead of delete q;