cc33fe570ac2abb37fe7eb5061b6335c55ee1458
[sbcl.git] / doc / ffi.sgml
1 <chapter id="ffi"><title>The Foreign Function Interface</>
2
3 <para>FIXME: The material in the &CMUCL; manual about the foreign
4 function interface should be reviewed, reformatted in DocBook, 
5 lightly edited for &SBCL;, and substituted into this manual. But in
6 the meantime, the original &CMUCL; manual is still 95+% correct for
7 the &SBCL; version of the foreign function interface. (The main
8 difference is that the package names have changed from
9 <quote><literal>ALIEN</></> and <quote><literal>C-CALL</></> to
10 <quote><literal>SB-ALIEN</></> and <quote><literal>SB-C-CALL</></>.)
11         <!-- FIXME: Oh, and I seem to remember that the CMUCL manual
12              was out of date about how to test for a null pointer,
13              there's a builtin operator to do it, you don't need to
14              do the nasty idiom the manual says you need to do. -->
15         <!-- FIXME: Also, the CMU CL alien documentation claims you
16              can just do (DEF-ALIEN-VARIABLE "errno" INT), which fails
17              with modern multithreading hacks. -->
18         <!-- FIXME: Also, LOAD-FOREIGN isn't implemented as of sbcl-0.6.7,
19              but LOAD-1-FOREIGN is. -->
20 See the sections
21 <itemizedlist>
22   <listitem><para>Type Translations</></>
23   <listitem><para>System Area Pointers</></>
24   <listitem><para>Alien Objects</></>
25   <listitem><para>Alien Types</></>
26   <listitem><para>Alien Operations</></>
27   <listitem><para>Alien Variables</></>
28   <listitem><para>Alien Function Calls</></>
29 </itemizedlist>
30 </para>
31
32 </chapter>