This commit is contained in:
agra
2026-03-05 16:20:36 +02:00
parent 22bc2439ce
commit f9dda972d2
36 changed files with 1063 additions and 7 deletions

View File

@@ -410,6 +410,7 @@ pub const Function = struct {
is_extern: bool = false,
is_comptime: bool = false,
linkage: Linkage = .internal,
call_conv: CallingConvention = .default,
pub const Param = struct {
name: StringId,
@@ -422,6 +423,11 @@ pub const Function = struct {
private,
};
pub const CallingConvention = enum {
default,
c,
};
pub fn init(name: StringId, params: []const Param, ret: TypeId) Function {
return .{
.name = name,