Hello everybody.
Ok, i jump...
I decide to begin the conversion of a unit (wrapper to other libraries + lot of
functions who link those libraries) into a universal fp library.
After Googling a while (and finding very poor doc, only few for Delphi, with
always the hypra-simple same example...), i do not find how to do with
classes...
Here a test (who gives me error)...
__________________________________________
library libtest;
uses
Classes, ctypes, Math, SysUtils;
type
TMyClass = class(TThread)
public
enabled1: boolean;
int1, int2: shortint;
function function1(): integer; cdecl;
end;
function TMyClass.function1(): integer; cdecl;
begin
if enabled1 then
result := int1 + int2 else result := -1;
end;
exports
TMyClass.function1();
end.
_______________________________________________________
Stop compil showing error at dot of function TMyClass.
=> libtest.pas(14,18) Fatal: Syntax error, ":" expected but "." found
PS : I promise, if i can do the conversion, to create a nice wiki, for dummies
like me : "How to create a universal (complicated) library with fpc"...
_______________________________________________
fpc-pascal maillist - [email protected]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal