gpu: fix redeclaration of function parameter errors
This changed in the latest version of Zig to be more strict. Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
9406326cd8
commit
381f2fe9c5
6 changed files with 22 additions and 22 deletions
|
|
@ -39,11 +39,11 @@ pub const Queue = opaque {
|
|||
) void {
|
||||
const Context = @TypeOf(context);
|
||||
const Helper = struct {
|
||||
pub fn callback(status: WorkDoneStatus, userdata: ?*anyopaque) callconv(.C) void {
|
||||
pub fn cCallback(status: WorkDoneStatus, userdata: ?*anyopaque) callconv(.C) void {
|
||||
callback(if (Context == void) {} else @ptrCast(Context, @alignCast(@alignOf(std.meta.Child(Context)), userdata)), status);
|
||||
}
|
||||
};
|
||||
Impl.queueOnSubmittedWorkDone(queue, signal_value, Helper.callback, if (Context == void) null else context);
|
||||
Impl.queueOnSubmittedWorkDone(queue, signal_value, Helper.cCallback, if (Context == void) null else context);
|
||||
}
|
||||
|
||||
pub inline fn setLabel(queue: *Queue, label: [*:0]const u8) void {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue