From 779604491348fc2b58d28067e051fe7529e27dff Mon Sep 17 00:00:00 2001 From: Garux Date: Tue, 22 Jun 2021 19:17:58 +0300 Subject: [PATCH] fix clang build error --- libs/math/curve.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/math/curve.h b/libs/math/curve.h index 6d76a90e..8d2d7cbc 100644 --- a/libs/math/curve.h +++ b/libs/math/curve.h @@ -42,7 +42,7 @@ double BernsteinPolynomial( double t ){ else if constexpr( I == 1 && Degree == 3 ) return 3 * ( 1 - t ) * ( 1 - t ) * t; else if constexpr( I == 2 && Degree == 3 ) return 3 * ( 1 - t ) * t * t; else if constexpr( I == 3 && Degree == 3 ) return t * t * t; - else 0 = 1; // general case not implemented + else static_assert( I != I, "general case not implemented" ); // assert on something false }