diff options
| author | Robin Voetter <robin@voetter.nl> | 2024-03-11 23:39:23 +0100 |
|---|---|---|
| committer | Robin Voetter <robin@voetter.nl> | 2024-03-18 19:13:49 +0100 |
| commit | e566158acf034105a43690501664c45b8a065f6a (patch) | |
| tree | f79acb4350a77fddcc9fff44a9cbd3c5f8384c3b /src/codegen/spirv/Module.zig | |
| parent | 9b058117f0f4595d43fbe08a3e659ac865e8b459 (diff) | |
| download | zig-e566158acf034105a43690501664c45b8a065f6a.tar.gz zig-e566158acf034105a43690501664c45b8a065f6a.zip | |
spirv: make IdResult an enum
Diffstat (limited to 'src/codegen/spirv/Module.zig')
| -rw-r--r-- | src/codegen/spirv/Module.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/codegen/spirv/Module.zig b/src/codegen/spirv/Module.zig index 61ef36162f..23b0d5d0db 100644 --- a/src/codegen/spirv/Module.zig +++ b/src/codegen/spirv/Module.zig @@ -215,12 +215,12 @@ pub fn deinit(self: *Module) void { pub fn allocId(self: *Module) spec.IdResult { defer self.next_result_id += 1; - return .{ .id = self.next_result_id }; + return @enumFromInt(self.next_result_id); } pub fn allocIds(self: *Module, n: u32) spec.IdResult { defer self.next_result_id += n; - return .{ .id = self.next_result_id }; + return @enumFromInt(self.next_result_id); } pub fn idBound(self: Module) Word { |
