Re: [xplc-general] C binding implementations
Cross-platform lightweight components
Status: Alpha
Brought to you by:
pphaneuf
|
From: Avery P. <ape...@ni...> - 2005-08-25 17:38:15
|
On Thu, Aug 25, 2005 at 12:23:11PM -0400, Pierre Phaneuf wrote: > Avery Pennarun wrote: > > > My xplcidl actually implements this in a different way, avoiding the > > horrible pain of manipulating stack frames and other stuff... but > > potentially with a performance penalty. (Hey, you're in a scripting > > language, how much worse can it be?) > > I don't recall the exact details... Didn't you generate a per-interface > bit of code? The magic with xptcall is that you don't need any compiled > code specific to the interface, you only need a description of the > interface (which is delivered in the binary code, or in "typelib" files, > and I plan on the XPLC version of the same being inlinable even in > scripting languages). Yes, you need a compiled bit of code for each interface: but if you're delivering your typelib in "binary code" anyway, then it might as well just be executable. There's no fundamental difference. Inlining that kind of stuff in scripting langugages is a bit funkier, but I'm not sure that's a good idea anyway. It reminds me of the old DATA statement in BASIC. Yeah, you could use it, and yeah, it was fine before they invented disks, but... > And did yours go both way (be able to implement an XPLC interface in a > scripting language)? The same concept could apply either way, although I only implemented one direction (IMHO by far the most common one for apps/libraries I know of). Have fun, Avery |