Browse thread
Camouflage 1.0
- Robbert VanRenesse
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Robbert VanRenesse <rvr@c...> |
| Subject: | Camouflage 1.0 |
Announcing Camouflage 1.0. Camouflage 1.0 is a tool that supports interfacing between C and OCaml. Camouflage reads a .mli file and creates the necessary C interfaces to the given module. This way the fact that a library is written in OCaml can be ``camouflaged.'' Camouflage also supports creating OCaml interfaces to C functions (``OCamlflaging'' a C library that way :-), and generates functions that convert between OCaml and C data structures. For example, let say "x.mli" contains the declaration "val add: int -> int -> int". Then the command "camou x.mli" creates a file "x.c" that contains the C function "int X_add(int, int)" which does all the stuff necessary to invoke the ML function. Vice versa, the declaration "external add: int -> int -> int" creates an ML function to invoke a corresponding C function. The current distribution (usable from Unix or Windows) may be obtained by ftp from ftp://ftp.cs.cornell.edu/pub/rvr/camou-1.0.tar.gz Bugs reports may be sent to me. Here's one bug: when invoking a C function from OCaml in interpreted mode, you can use only 5 parameters or less. Easy to fix, but I haven't done it yet... Enjoy, Robbert