Import Debian changes 20180207-1
[hcoop/debian/mlton.git] / mlton / atoms / ffi.sig
CommitLineData
7f918cf1
CE
1(* Copyright (C) 2009 Matthew Fluet.
2 * Copyright (C) 2004-2006 Henry Cejtin, Matthew Fluet, Suresh
3 * Jagannathan, and Stephen Weeks.
4 *
5 * MLton is released under a BSD-style license.
6 * See the file MLton-LICENSE for details.
7 *)
8
9signature FFI_STRUCTS =
10 sig
11 structure CFunction: C_FUNCTION
12 structure CType: C_TYPE
13 end
14
15signature FFI =
16 sig
17 include FFI_STRUCTS
18
19 val addExport: {args: CType.t vector,
20 convention: CFunction.Convention.t,
21 name: string,
22 res: CType.t option,
23 symbolScope: CFunction.SymbolScope.t} -> int
24 val addSymbol: {ty: CType.t,
25 name: string,
26 symbolScope: CFunction.SymbolScope.t} -> unit
27 val checkScope: {name: string,
28 symbolScope: CFunction.SymbolScope.t} ->
29 CFunction.SymbolScope.t
30 val declareExports: {print: string -> unit} -> unit
31 val declareHeaders: {print: string -> unit} -> unit
32 val numExports: unit -> int
33 end