mach: correct WebGPU C ABI export

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
Stephen Gutekanst 2022-10-11 01:06:48 +02:00
parent 58f7121a3d
commit c94dee263b

View file

@ -558,14 +558,13 @@ var app: App = undefined;
pub const GPUInterface = gpu.dawn.Interface; pub const GPUInterface = gpu.dawn.Interface;
const _ = gpu.Export(GPUInterface);
pub fn main() !void { pub fn main() !void {
var gpa = std.heap.GeneralPurposeAllocator(.{}){}; var gpa = std.heap.GeneralPurposeAllocator(.{}){};
defer _ = gpa.deinit(); defer _ = gpa.deinit();
const allocator = gpa.allocator(); const allocator = gpa.allocator();
gpu.Impl.init(); gpu.Impl.init();
_ = gpu.Export(GPUInterface);
var core = try coreInit(allocator); var core = try coreInit(allocator);
defer coreDeinit(core, allocator); defer coreDeinit(core, allocator);