How do I get access to FastMM4's RegisterExpectedMemoryLeak?

2k views Asked by At

I'm using Delphi's fastMM memory manager and I fail when I try to use the full debug mode.

I get the following errors when compiling:

FastMM\FastMM4.pas(6872) Error: Undeclared identifier: 'RegisterExpectedMemoryLeak'
FastMM\FastMM4.pas(6948) Error: Undeclared identifier: 'UnregisterExpectedMemoryLeak'
FastMM\FastMM4.pas(9269)
import_test.dpr(24) Fatal: Could not compile used unit 'FastMM\FastMM4.pas'

The .inc file tells to load the full debug dll. I've already copied the FastMM_FullDebugMode.dll file everywhere. It looks like I should have included something in my project.

I'm probably missing something really obvious.

The Delphi version is 7.

1

There are 1 answers

3
Ondrej Kelle On BEST ANSWER

Turn on the EnableMemoryLeakReporting directive in the include file FastMM4Options.inc by changing it from:

{.$define EnableMemoryLeakReporting}

to:

{$define EnableMemoryLeakReporting}

Also read the comments in that file and understand the various options, turn them on/off as needed.