From 60931719d898d435cc63b6c7baa5d301c289717c Mon Sep 17 00:00:00 2001 From: Marcio T Date: Sat, 26 Nov 2022 20:11:14 -0700 Subject: [PATCH] =?UTF-8?q?=F0=9F=A9=B9=20Fix=20ADVANCE=5FK=20+=20DISTINCT?= =?UTF-8?q?=5FE=5FFACTORS=20sanity=20check=20(#25007)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Marlin/src/inc/SanityCheck.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Marlin/src/inc/SanityCheck.h b/Marlin/src/inc/SanityCheck.h index 685411c20be6..766b69fcb98c 100644 --- a/Marlin/src/inc/SanityCheck.h +++ b/Marlin/src/inc/SanityCheck.h @@ -1353,7 +1353,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS #if ENABLED(LIN_ADVANCE) #if DISTINCT_E > 1 constexpr float lak[] = ADVANCE_K; - static_assert(COUNT(lak) < DISTINCT_E, "The ADVANCE_K array has too many elements (i.e., more than " STRINGIFY(DISTINCT_E) ")."); + static_assert(COUNT(lak) <= DISTINCT_E, "The ADVANCE_K array has too many elements (i.e., more than " STRINGIFY(DISTINCT_E) ")."); #define _LIN_ASSERT(N) static_assert(N >= COUNT(lak) || WITHIN(lak[N], 0, 10), "ADVANCE_K values must be from 0 to 10 (Changed in LIN_ADVANCE v1.5, Marlin 1.1.9)."); REPEAT(DISTINCT_E, _LIN_ASSERT) #undef _LIN_ASSERT