src/compiler: Fix warning C4244 'argument' : conversion from 'type1' to 'type2', possible loss of data
Reviewed-By: Jesse Natalie <jenatali@microsoft.com> Reviewed-by: Jesse Natalie <None> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32979>
This commit is contained in:
@@ -329,9 +329,9 @@ nir_const_value_for_raw_uint(uint64_t x, unsigned bit_size)
|
||||
/* clang-format off */
|
||||
switch (bit_size) {
|
||||
case 1: v.b = x; break;
|
||||
case 8: v.u8 = x; break;
|
||||
case 16: v.u16 = x; break;
|
||||
case 32: v.u32 = x; break;
|
||||
case 8: v.u8 = (uint8_t)x; break;
|
||||
case 16: v.u16 = (uint16_t)x; break;
|
||||
case 32: v.u32 = (uint32_t)x; break;
|
||||
case 64: v.u64 = x; break;
|
||||
default:
|
||||
unreachable("Invalid bit size");
|
||||
|
||||
Reference in New Issue
Block a user