Skip to content

ShaderSourceSPIRV::codeSize should have been a size_t #592

Description

@Kangz
/**
 * Default values can be set using @ref WGPU_SHADER_SOURCE_SPIRV_INIT as initializer.
 */
typedef struct WGPUShaderSourceSPIRV {
    WGPUChainedStruct chain;
    /**
     * The `INIT` macro sets this to `0`.
     */
    uint32_t codeSize;
    /**
     * The `INIT` macro sets this to `NULL`.
     */
    uint32_t const * code;
} WGPUShaderSourceSPIRV WGPU_STRUCTURE_ATTRIBUTE;

Every other array type in webgpu.h uses size_t for its size, but for some reason we didn't do it for ShaderSourceSPIRV::codeSize. Is this something that we can fix? It would be a breaking change, so it might not be possible.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions