unreachable() doesn't lead to executing the code that follows it,
neither in debug nor release builds. So falling through doesn't make any
sense.
This fixes a compile-error on clang.
Let's move the default-block to the end to make it clearer that there's
no intended fallthrough.
Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15531>
struct pvr_buffer *buffer = state->index_buffer_binding.buffer;
switch (state->index_buffer_binding.type) {
- default:
- unreachable("Invalid index type");
- FALLTHROUGH;
-
case VK_INDEX_TYPE_UINT32:
list0.index_size = PVRX(VDMCTRL_INDEX_SIZE_B32);
index_stride = 4;
list0.index_size = PVRX(VDMCTRL_INDEX_SIZE_B16);
index_stride = 2;
break;
+
+ default:
+ unreachable("Invalid index type");
}
list0.index_addr_present = true;