[fpc-pascal]My object function is overriding real function

Matt Emson memsom at interalpha.co.uk
Thu Feb 19 10:50:39 CET 2004


> I have a object that connects to a speech server, festival. In my
> object, I define a function called close. This must close the socket
> connection, which is done by the function close. Therefore, I am having
> a problem, because simply calling close with the sin and sout parameters
> results in an error because it is calling my objects close function
> which takes no parameters.

Simple answer, qualify the function or procedure with the unit name.

e.g.

   SocketFuncs.Close;

where 'SocketFuncs' contains the routine clashing with your other function.

Matt





More information about the fpc-pascal mailing list