Lazarus

Programming => Packages and Libraries => KOL => Topic started by: Pipy71 on October 14, 2011, 11:19:41 am

Title: Forward declaration not solved "dbgMemRange(PByte,LongInt,LongInt="0"):AnsiStrin
Post by: Pipy71 on October 14, 2011, 11:19:41 am
I have this problem when building KOL application....

C:\lazarus-0_9_30_2RC1\components\codetools\fileprocs.pas(360,10) Error: Forward declaration not solved "dbgMemRange(PByte,LongInt,LongInt="0"):AnsiString;"

This problem is discussed here....

 http://bugs.freepascal.org/bug_view_advanced_page.php?bug_id=18537  (http://bugs.freepascal.org/bug_view_advanced_page.php?bug_id=18537)

The solution is 'PByte is declared in implementation'

Where ? please advise how i fix this problem.

Thanks
Title: Re: Forward declaration not solved "dbgMemRange(PByte,LongInt,LongInt="0"):AnsiStrin
Post by: typo on October 14, 2011, 02:14:20 pm
Paul Ishinen has said that it is declared twice. Find one of them and cancel it or change its name. It is on the implementation section.
Title: Re: Forward declaration not solved "dbgMemRange(PByte,LongInt,LongInt="0"):AnsiStrin
Post by: Pipy71 on October 14, 2011, 04:40:17 pm
I am sorry this is only my second day with lazarus.

I understand its declared twice -  but what is declared twice  'P' or 'dbgMemRange' ?

In fileprocs.pas...

Code: [Select]
                 function DbgSName(const p: TObject): string; overload;
                 function DbgSdbgMemRangeName(const p: TClass): string; overload;
line 360:   function (P: PByte; Count: integer; Width: integer = 0): string; overload;

change to
Code: [Select]
function DbgSName(const p: TObject): string; overload;
function DbgSdbgMemRangeName(const p: TClass): string; overload;
// function (P: PByte; Count: integer; Width: integer = 0): string; overload;

if I comment out the last line then the application will build.
But I cannot find this function being declared anywhere else or in any other file.
So am I correct in commenting this line out ?

Thanks

TinyPortal © 2005-2018