manual c function interop
This commit is contained in:
+24
-7
@@ -7,6 +7,21 @@ import "core:mem"
|
||||
|
||||
INVALID_ID :: -1
|
||||
|
||||
Calling_Convention :: enum {
|
||||
Brolang,
|
||||
C,
|
||||
}
|
||||
|
||||
Implementation :: enum {
|
||||
Definition,
|
||||
Declaration,
|
||||
}
|
||||
|
||||
Linkage :: enum {
|
||||
Internal,
|
||||
External,
|
||||
}
|
||||
|
||||
Opcode :: enum {
|
||||
Param,
|
||||
Const,
|
||||
@@ -35,13 +50,15 @@ Instruction :: struct {
|
||||
}
|
||||
|
||||
Function :: struct {
|
||||
link_name: string,
|
||||
c_abi: bool,
|
||||
is_main: bool,
|
||||
param_types: []types.Type,
|
||||
result: types.Type,
|
||||
instructions: []Instruction,
|
||||
problematic: bool,
|
||||
link_name: string,
|
||||
calling_convention: Calling_Convention,
|
||||
implementation: Implementation,
|
||||
linkage: Linkage,
|
||||
is_main: bool,
|
||||
param_types: []types.Type,
|
||||
result: types.Type,
|
||||
instructions: []Instruction,
|
||||
problematic: bool,
|
||||
}
|
||||
|
||||
Global :: struct {
|
||||
|
||||
Reference in New Issue
Block a user