[kaffe] Question about function 'sysdepCallMethod'
qi fenghai
arqhaifeng at hotmail.com
Wed Nov 2 06:56:24 PST 2005
Hi all, Please advise if 'sysdepCallMethod' can be implemented by this way
as bellow:
method 1:
in JVM:
typedef int (*FUNCTYPE)(); //function's return type is int
FUNCTYPE *nativefunc = (FUNCTYPE)dlsym(handle, "foo");
//four argument
(*nativefunc)(1, 2.5);
in share library:
int foo(int, double);
method 2:
in JVM:
typedef int (*FUNCTYPE)(...); //function's return type is int,
argument list is '...'
FUNCTYPE *nativefunc = (FUNCTYPE)dlsym(handle, "foo");
//four argument
(*nativefunc)(1, 2.5);
in share library:
int foo(int, double);
_________________________________________________________________
与联机的朋友进行交流,请使用 MSN Messenger: http://messenger.msn.com/cn
More information about the kaffe
mailing list