From b5cc4c01a9a67a3e0dd57949d24e416b3de3e50d Mon Sep 17 00:00:00 2001 From: Simon Rozman Date: Wed, 11 Jun 2025 09:55:41 +0200 Subject: [PATCH] math: fix align_up declaration Using add() which is non-constexpr, the align_up() itself may not be constexpr. Signed-off-by: Simon Rozman --- include/stdex/math.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/stdex/math.hpp b/include/stdex/math.hpp index b62ad2886..3169fe5e7 100644 --- a/include/stdex/math.hpp +++ b/include/stdex/math.hpp @@ -89,7 +89,7 @@ namespace stdex /// /// \return The first number greater or equal to a that has n lower bits zero /// - inline constexpr size_t align_up(size_t a, int n) + inline size_t align_up(size_t a, int n) { const size_t mask = SIZE_MAX << n; return add(a, ~mask) & mask;