I tried to create FireMonkey application today and added ReportMemoryLeaksOnShutdown to project file to detect memory leaks, but this is not working in FireMonkey. Can you tell me, what's the problem? Is this somekind of a bug?
My code on project file:
{$IFDEF DEBUG}
ReportMemoryLeaksOnShutdown := True;
{$ENDIF}
Application.Initialize;
Application.CreateForm(TfrmMain, frmMain);
Application.Run;
And my code that must generate memory leak:
procedure TfrmMain.Button1Click(Sender: TObject);
var
lStrings: TStringList;
begin
lStrings := TStringList.Create;
lStrings.Add('test');
ShowMessage(lStrings.CommaText);
end;
I have Debug configuration active but not getting any memory leaks reported.