mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 16:08:04 +02:00
zink: avoid designated initializers as they are not supported in C++ < 20
error C7555: use of designated initializers requires at least '/std:c++20'
Fixes: 7bdaf6e95f ("zink: use zink_shader_key_optimal unions for pipeline state asserts")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29139>
This commit is contained in:
parent
320c0b44f4
commit
654ef35635
1 changed files with 2 additions and 1 deletions
|
|
@ -128,7 +128,8 @@ zink_get_gfx_pipeline(struct zink_context *ctx,
|
|||
/* extra safety asserts for optimal path to catch refactoring bugs */
|
||||
if (prog->optimal_keys) {
|
||||
ASSERTED const union zink_shader_key_optimal *opt = (union zink_shader_key_optimal*)&prog->last_variant_hash;
|
||||
ASSERTED union zink_shader_key_optimal sanitized{.val = zink_sanitize_optimal_key(ctx->gfx_stages, ctx->gfx_pipeline_state.shader_keys_optimal.key.val)};
|
||||
ASSERTED union zink_shader_key_optimal sanitized = {};
|
||||
sanitized.val = zink_sanitize_optimal_key(ctx->gfx_stages, ctx->gfx_pipeline_state.shader_keys_optimal.key.val);
|
||||
assert(opt->val == sanitized.val);
|
||||
assert(state->optimal_key == sanitized.val);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue