Map Database  •  FAQ  •  RSS  •  Login

Compiler Error - Overloaded Function in Source Code?

<<

Mritter26

Post 05 Aug 2013, 23:24

Compiler Error - Overloaded Function in Source Code?

I recently followed the step by step guide for compiling the source code project, didn't change a thing, but I ran into an error on line 414 in KM_Points that states the following:

\castlesand\KM_Points.pas(414,13) Error: Can't determine which overloaded function to call
\castlesand\KM_Points.pas(389,10) Hint: Found declaration: KMGetDirection(Single,Single):<enumeration type>;
\castlesand\KM_Points.pas(372,10) Hint: Found declaration: KMGetDirection(LongInt,LongInt):<enumeration type>;
\castlesand\KM_Points.pas(713) Fatal: There were 1 errors compiling module, stopping


The function is coded as follows:
function KMGetDirection(FromPos, ToPos: TKMPoint): TKMDirection;
begin
Result := KMGetDirection(ToPos.X - FromPos.X, ToPos.Y - FromPos.Y);
end;

I, for the life of me, cannot figure out where this error is coming from. I understand overloading and everything seems to be great. I'm using Lazarus IDE v1.0.10 and I'm familiar with using Java/C++ but not Pascal so please forgive me if this is a stupid question. Thanks!
<<

Lewin

User avatar

KaM Remake Developer

Posts: 3822

Joined: 16 Sep 2007, 22:00

KaM Skill Level: Skilled

ICQ: 269127056

Website: http://lewin.hodgman.id.au

Yahoo Messenger: lewinlewinhodgman

Location: Australia

Post 06 Aug 2013, 01:24

Re: Compiler Error - Overloaded Function in Source Code?

That happens when you use the 64 bit version of Lazarus. We currently only support 32 bit compiling. 64 bit support wouldn't be hard to add, it just needs some renaming/fixing in the source code, and currently we have no motivation since 64 bit won't really bring any advantages (we use 64 bit data types rarely). Even big game engines like Crysis get pretty much the same performance in the 32 and 64 bit versions.

Return to “Bugs”

Who is online

Users browsing this forum: No registered users and 5 guests