Re: [PATCH v3 0/5] MR781: Avoid HLSL_CLASS_OBJECT, part 4.
Giovanni Mascellani (@giomasce) commented about libs/vkd3d-shader/d3dbc.c:
return D3DXPC_STRUCT; case HLSL_CLASS_VECTOR: return D3DXPC_VECTOR; - default: - ERR("Invalid class %#x.\n", type->class); - vkd3d_unreachable(); + case HLSL_CLASS_VOID: + /* This shouldn't happen. */
Is the comment useful? Doesn't the following `vkd3d_unreachable()` already convey that information? Also, could you please add a `break`? clang seems to be touchy about it: ``` ../libs/vkd3d-shader/d3dbc.c:1521:30: error: label at end of compound statement: expected statement case HLSL_CLASS_VOID: ^ ; 1 error generated. make[1]: *** [libs/vkd3d-shader/libvkd3d_shader_la-d3dbc.lo] Error 1 ``` -- https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/781#note_67909
participants (1)
-
Giovanni Mascellani (@giomasce)