gpu: add CompilationMessage

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
Stephen Gutekanst 2022-07-15 20:31:13 -07:00 committed by Stephen Gutekanst
parent e28959c1cf
commit ad45016481
2 changed files with 10 additions and 10 deletions

View file

@ -1,13 +1,3 @@
typedef struct WGPUCompilationMessage {
next_in_chain: *const ChainedStruct,
char const * message; // nullable
WGPUCompilationMessageType type;
line_num: u64,
line_pos: u64,
offset: u64,
length: u64,
} WGPUCompilationMessage;
typedef struct WGPUConstantEntry {
next_in_chain: *const ChainedStruct,
char const * key;

View file

@ -430,6 +430,16 @@ pub const Origin3D = extern struct {
z: u32 = 0,
};
pub const CompilationMessage = extern struct {
next_in_chain: *const ChainedStruct,
message: ?[*:0]const u8 = null,
type: CompilationMessageType,
line_num: u64,
line_pos: u64,
offset: u64,
length: u64,
};
test "BackendType name" {
try testing.expectEqualStrings("Vulkan", BackendType.vulkan.name());
}