Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions test/mock/kernel/mock_framework.zig
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ const DataElement = union(DataElementType) {
PTR_CONST_GdtPtr: *const gdt.GdtPtr,
PTR_CONST_IdtPtr: *const idt.IdtPtr,
ERROR_IDTERROR_VOID: idt.IdtError!void,
EFN_OVOID: extern fn () void,
EFN_OVOID: fn () callconv(.C) void,
NFN_OVOID: fn () callconv(.Naked) void,
FN_OVOID: fn () void,
FN_OUSIZE: fn () usize,
Expand All @@ -81,7 +81,7 @@ const DataElement = union(DataElementType) {
FN_IECmosStatusRegister_IBOOL_OU8: fn (cmos.StatusRegister, bool) u8,
FN_IECmosStatusRegister_IU8_IBOOL_OVOID: fn (cmos.StatusRegister, u8, bool) void,
FN_IECmosRtcRegister_OU8: fn (cmos.RtcRegister) u8,
FN_IU8_IEFNOVOID_OERRORIDTERRORVOID: fn (u8, extern fn () void) idt.IdtError!void,
FN_IU8_IEFNOVOID_OERRORIDTERRORVOID: fn (u8, fn () callconv(.C) void) idt.IdtError!void,
FN_IU8_INFNOVOID_OERRORIDTERRORVOID: fn (u8, fn () callconv(.Naked) void) idt.IdtError!void,
FN_IPTRCONSTGDTPTR_OVOID: fn (*const gdt.GdtPtr) void,
FN_IPTRCONSTIDTPTR_OVOID: fn (*const idt.IdtPtr) void,
Expand Down Expand Up @@ -170,7 +170,7 @@ fn Mock() type {
*const gdt.GdtPtr => DataElement{ .PTR_CONST_GdtPtr = arg },
*const idt.IdtPtr => DataElement{ .PTR_CONST_IdtPtr = arg },
idt.IdtError!void => DataElement{ .ERROR_IDTERROR_VOID = arg },
extern fn () void => DataElement{ .EFN_OVOID = arg },
fn () callconv(.C) void => DataElement{ .EFN_OVOID = arg },
fn () callconv(.Naked) void => DataElement{ .NFN_OVOID = arg },
fn () void => DataElement{ .FN_OVOID = arg },
fn () usize => DataElement{ .FN_OUSIZE = arg },
Expand All @@ -188,7 +188,7 @@ fn Mock() type {
fn (cmos.RtcRegister) u8 => DataElement{ .FN_IECmosRtcRegister_OU8 = arg },
fn (*const gdt.GdtPtr) void => DataElement{ .FN_IPTRCONSTGDTPTR_OVOID = arg },
fn (*const idt.IdtPtr) void => DataElement{ .FN_IPTRCONSTIDTPTR_OVOID = arg },
fn (u8, extern fn () void) idt.IdtError!void => DataElement{ .FN_IU8_IEFNOVOID_OERRORIDTERRORVOID = arg },
fn (u8, fn () callconv(.C) void) idt.IdtError!void => DataElement{ .FN_IU8_IEFNOVOID_OERRORIDTERRORVOID = arg },
fn (u8, fn () callconv(.Naked) void) idt.IdtError!void => DataElement{ .FN_IU8_INFNOVOID_OERRORIDTERRORVOID = arg },
else => @compileError("Type not supported: " ++ @typeName(@TypeOf(arg))),
};
Expand All @@ -215,7 +215,7 @@ fn Mock() type {
*const gdt.GdtPtr => DataElement.PTR_CONST_GdtPtr,
*const idt.IdtPtr => DataElement.PTR_CONST_IdtPtr,
idt.IdtError!void => DataElement.ERROR_IDTERROR_VOID,
extern fn () void => DataElementType.EFN_OVOID,
fn () callconv(.C) void => DataElementType.EFN_OVOID,
fn () callconv(.Naked) void => DataElementType.NFN_OVOID,
fn () void => DataElementType.FN_OVOID,
fn () u16 => DataElementType.FN_OU16,
Expand All @@ -232,7 +232,7 @@ fn Mock() type {
fn (cmos.RtcRegister) u8 => DataElementType.FN_IECmosRtcRegister_OU8,
fn (*const gdt.GdtPtr) void => DataElementType.FN_IPTRCONSTGDTPTR_OVOID,
fn (*const idt.IdtPtr) void => DataElementType.FN_IPTRCONSTIDTPTR_OVOID,
fn (u8, extern fn () void) idt.IdtError!void => DataElementType.FN_IU8_IEFNOVOID_OERRORIDTERRORVOID,
fn (u8, fn () callconv(.C) void) idt.IdtError!void => DataElementType.FN_IU8_IEFNOVOID_OERRORIDTERRORVOID,
fn (u8, fn () callconv(.Naked) void) idt.IdtError!void => DataElementType.FN_IU8_INFNOVOID_OERRORIDTERRORVOID,
else => @compileError("Type not supported: " ++ @typeName(T)),
};
Expand Down Expand Up @@ -261,7 +261,7 @@ fn Mock() type {
*const gdt.GdtPtr => element.PTR_CONST_GdtPtr,
*const idt.IdtPtr => element.PTR_CONST_IdtPtr,
idt.IdtError!void => element.ERROR_IDTERROR_VOID,
extern fn () void => element.EFN_OVOID,
fn () callconv(.C) void => element.EFN_OVOID,
fn () callconv(.Naked) void => element.NFN_OVOID,
fn () void => element.FN_OVOID,
fn () u16 => element.FN_OU16,
Expand All @@ -278,7 +278,7 @@ fn Mock() type {
fn (cmos.RtcRegister) u8 => element.FN_IECmosRtcRegister_OU8,
fn (*const gdt.GdtPtr) void => element.FN_IPTRCONSTGDTPTR_OVOID,
fn (*const idt.IdtPtr) void => element.FN_IPTRCONSTIDTPTR_OVOID,
fn (u8, extern fn () void) idt.IdtError!void => element.FN_IU8_IEFNOVOID_OERRORIDTERRORVOID,
fn (u8, fn () callconv(.C) void) idt.IdtError!void => element.FN_IU8_IEFNOVOID_OERRORIDTERRORVOID,
fn (u8, fn () callconv(.Naked) void) idt.IdtError!void => element.FN_IU8_INFNOVOID_OERRORIDTERRORVOID,
else => @compileError("Type not supported: " ++ @typeName(T)),
};
Expand Down