This is the mail archive of the kawa@sources.redhat.com mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: feature request primitive-native-method


On Thu, 20 Mar 2003 16:07:18 -0800
Per Bothner <per at bothner dot com> wrote:

> Vladimir Tsichevski wrote:
> > subject says it all. It would be convenient to call native methods from 
> > Scheme without writing Java sources just to describe them.
> 
> That's not possible.  The 'native' attribute of a method
> is an attribute of its *implementation*, not its call.
> There is no way to express in bytecode *calling* native
> code.
> 
> Note the existing primitive-xxx-method macros do not
> generate metyhod - they just generate *references* to
> method, that must already exist.
> 
> What one could do is have some way to automatically
> generate a dummy Java class that has a native method,
> and perhaps at the same time generate the JNI wrapper
> that calls a C function.  But that's a non-trivial
> task, starting with the design (which should ideally
> be compatible with existing Foreign Function Interfaces).

shouldn't we use something like swig for that?

http://www.swig.org/

> -- 
> 	--Per Bothner
> per at bothner dot com   http://per.bothner.com/
> 
> 
> 


-- 

Stanislas Pinte

Computer Consultant

	98, rue Bois l'Evêque
	B-4000 Liège

web:		http://www.altosw.be
email:		alto_stan at wanadoo dot be


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]