diff options
-rw-r--r-- | source/blender/blenlib/BLI_color_mix.hh | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/BLI_ghash.c | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/BLI_kdopbvh.c | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/array_utils.c | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/math_color.c | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/math_matrix.c | 12 | ||||
-rw-r--r-- | source/blender/blenlib/intern/math_rotation.c | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/string_cursor_utf8.c | 4 | ||||
-rw-r--r-- | source/blender/blenlib/intern/threads.cc | 2 | ||||
-rw-r--r-- | source/blender/blenlib/tests/BLI_array_store_test.cc | 2 |
10 files changed, 16 insertions, 16 deletions
diff --git a/source/blender/blenlib/BLI_color_mix.hh b/source/blender/blenlib/BLI_color_mix.hh index 4989ddc609e..322da2bf112 100644 --- a/source/blender/blenlib/BLI_color_mix.hh +++ b/source/blender/blenlib/BLI_color_mix.hh @@ -1042,7 +1042,7 @@ BLI_INLINE Color BLI_mix_colors(const IMB_BlendMode tool, case IMB_BLEND_COLOR: return mix_color<Color, Traits>(a, b, alpha); default: - BLI_assert(0); + BLI_assert_unreachable(); return Color(0, 0, 0, 0); } } diff --git a/source/blender/blenlib/intern/BLI_ghash.c b/source/blender/blenlib/intern/BLI_ghash.c index 57e05233efa..e6ff5bab8a1 100644 --- a/source/blender/blenlib/intern/BLI_ghash.c +++ b/source/blender/blenlib/intern/BLI_ghash.c @@ -173,7 +173,7 @@ BLI_INLINE uint ghash_find_next_bucket_index(const GHash *gh, uint curr_bucket) return curr_bucket; } } - BLI_assert(0); + BLI_assert_unreachable(); return 0; } diff --git a/source/blender/blenlib/intern/BLI_kdopbvh.c b/source/blender/blenlib/intern/BLI_kdopbvh.c index 0f52c84c45e..62bf17bd415 100644 --- a/source/blender/blenlib/intern/BLI_kdopbvh.c +++ b/source/blender/blenlib/intern/BLI_kdopbvh.c @@ -893,7 +893,7 @@ BVHTree *BLI_bvhtree_new(int maxsize, float epsilon, char tree_type, char axis) } else { /* should never happen! */ - BLI_assert(0); + BLI_assert_unreachable(); goto fail; } diff --git a/source/blender/blenlib/intern/array_utils.c b/source/blender/blenlib/intern/array_utils.c index f1f1dd60ddf..a401059755d 100644 --- a/source/blender/blenlib/intern/array_utils.c +++ b/source/blender/blenlib/intern/array_utils.c @@ -53,7 +53,7 @@ void _bli_array_wrap(void *arr_v, uint arr_len, size_t arr_stride, int dir) memcpy(arr, buf, arr_stride); } else { - BLI_assert(0); + BLI_assert_unreachable(); } } diff --git a/source/blender/blenlib/intern/math_color.c b/source/blender/blenlib/intern/math_color.c index 07e9eaf0f42..52cbda82268 100644 --- a/source/blender/blenlib/intern/math_color.c +++ b/source/blender/blenlib/intern/math_color.c @@ -166,7 +166,7 @@ void ycc_to_rgb(float y, float cb, float cr, float *r_r, float *r_g, float *r_b, b = y + 1.772f * cb - 226.816f; break; default: - BLI_assert(0); + BLI_assert_unreachable(); break; } *r_r = r / 255.0f; diff --git a/source/blender/blenlib/intern/math_matrix.c b/source/blender/blenlib/intern/math_matrix.c index f295734706f..ce9abc36cad 100644 --- a/source/blender/blenlib/intern/math_matrix.c +++ b/source/blender/blenlib/intern/math_matrix.c @@ -1496,7 +1496,7 @@ void orthogonalize_m3(float R[3][3], int axis) } break; default: - BLI_assert(0); + BLI_assert_unreachable(); break; } mul_v3_fl(R[0], size[0]); @@ -1580,7 +1580,7 @@ void orthogonalize_m4(float R[4][4], int axis) } break; default: - BLI_assert(0); + BLI_assert_unreachable(); break; } mul_v3_fl(R[0], size[0]); @@ -1654,7 +1654,7 @@ void orthogonalize_m3_stable(float R[3][3], int axis, bool normalize) orthogonalize_stable(R[2], R[0], R[1], normalize); break; default: - BLI_assert(0); + BLI_assert_unreachable(); break; } } @@ -1672,7 +1672,7 @@ void orthogonalize_m4_stable(float R[4][4], int axis, bool normalize) orthogonalize_stable(R[2], R[0], R[1], normalize); break; default: - BLI_assert(0); + BLI_assert_unreachable(); break; } } @@ -1734,7 +1734,7 @@ static bool orthogonalize_m3_zero_axes_impl(float *mat[3], const float unit_leng break; } default: { - BLI_assert(0); /* Unreachable! */ + BLI_assert_unreachable(); } } @@ -2338,7 +2338,7 @@ void rotate_m4(float mat[4][4], const char axis, const float angle) } break; default: - BLI_assert(0); + BLI_assert_unreachable(); break; } } diff --git a/source/blender/blenlib/intern/math_rotation.c b/source/blender/blenlib/intern/math_rotation.c index 4cd377b109e..92223bdf1d5 100644 --- a/source/blender/blenlib/intern/math_rotation.c +++ b/source/blender/blenlib/intern/math_rotation.c @@ -1143,7 +1143,7 @@ void axis_angle_to_mat3_single(float R[3][3], const char axis, const float angle R[2][2] = 1.0f; break; default: - BLI_assert(0); + BLI_assert_unreachable(); break; } } diff --git a/source/blender/blenlib/intern/string_cursor_utf8.c b/source/blender/blenlib/intern/string_cursor_utf8.c index a6e68401368..7a23b4bb4ad 100644 --- a/source/blender/blenlib/intern/string_cursor_utf8.c +++ b/source/blender/blenlib/intern/string_cursor_utf8.c @@ -198,7 +198,7 @@ void BLI_str_cursor_step_utf8(const char *str, } } else { - BLI_assert(0); + BLI_assert_unreachable(); } } @@ -296,6 +296,6 @@ void BLI_str_cursor_step_utf32(const char32_t *str, } } else { - BLI_assert(0); + BLI_assert_unreachable(); } } diff --git a/source/blender/blenlib/intern/threads.cc b/source/blender/blenlib/intern/threads.cc index 70c1e701348..37fccf6f4fe 100644 --- a/source/blender/blenlib/intern/threads.cc +++ b/source/blender/blenlib/intern/threads.cc @@ -348,7 +348,7 @@ static ThreadMutex *global_mutex_from_type(const int type) case LOCK_VIEW3D: return &_view3d_lock; default: - BLI_assert(0); + BLI_assert_unreachable(); return nullptr; } } diff --git a/source/blender/blenlib/tests/BLI_array_store_test.cc b/source/blender/blenlib/tests/BLI_array_store_test.cc index aa7291e1b41..20e2a4d88f8 100644 --- a/source/blender/blenlib/tests/BLI_array_store_test.cc +++ b/source/blender/blenlib/tests/BLI_array_store_test.cc @@ -644,7 +644,7 @@ static void testbuffer_list_state_random_data(ListBase *lb, break; } default: - BLI_assert(0); + BLI_assert_unreachable(); } } } |