nir: fix intrinsic builders on MSVC C++
Fix this error:
error C4576: a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Fixes: c9bcad2573
("nir: add generated intrinsic builders")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7808>
This commit is contained in:
parent
517b698661
commit
7a77008283
|
@ -138,8 +138,13 @@ _nir_build_${name}(nir_builder *build${intrinsic_decl_list(opcode)})
|
|||
|
||||
% for name, opcode in sorted(INTR_OPCODES.items()):
|
||||
% if opcode.indices:
|
||||
#ifdef __cplusplus
|
||||
#define nir_build_${name}(build${intrinsic_macro_list(opcode)}, ...) ${'\\\\'}
|
||||
_nir_build_${name}(build${intrinsic_macro_list(opcode)}, _nir_${name}_indices{0, __VA_ARGS__})
|
||||
#else
|
||||
#define nir_build_${name}(build${intrinsic_macro_list(opcode)}, ...) ${'\\\\'}
|
||||
_nir_build_${name}(build${intrinsic_macro_list(opcode)}, (struct _nir_${name}_indices){0, __VA_ARGS__})
|
||||
#endif
|
||||
% else:
|
||||
#define nir_build_${name} _nir_build_${name}
|
||||
% endif
|
||||
|
|
Loading…
Reference in New Issue