[gambit-list] Gerbil: FFI Gerbil modules, why instead of a single Scheme file, a .ssi with (extern ..) + a .scm?
vyzo at hackzen.org
Tue Oct 22 11:46:02 EDT 2019
What do you mean why? If you want to write ffi code, you need to drop down
to straight gambit code, and that's what being-foreign does.
begin-ffi is a macro on top, you can look at its definition in :std/foreign.
On Tue, Oct 22, 2019 at 6:29 PM Adam <adam.mlmb at gmail.com> wrote:
> Ah there's also |begin-foreign| and |begin-ffi|, why?
> On Tue, 22 Oct 2019 at 23:23, Adam <adam.mlmb at gmail.com> wrote:
>> Hi Vyzo,
>> Browsing Gerbil modules for instance here
>> https://github.com/vyzo/gerbil/tree/master/src/std/db I see that FFI
>> modules tend to have a non-standard format, instead of just being a file
>> whateverclibmodule.scm (or .ss in the Gerbil convention, though .scm is
>> supported since last week right) which contains normal Scheme and Scheme
>> FFI code interspersed e.g. (define-c-lambda funame ...) implies (export
>> , you have a .scm file and a .ssi file, where the .ssi contains (extern
>> Why is this?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Gambit-list