Re: [PATCH v7 04/10] rust: num: make Bounded::get const

From: Gary Guo

Date: Fri Feb 27 2026 - 07:36:38 EST


On Tue Feb 24, 2026 at 2:21 PM GMT, Alexandre Courbot wrote:
> There is a need to access the inner value of a `Bounded` in const
> context, notably for bitfields and registers. Remove the invariant check
> of `Bounded::get`, which allows us to make it const.
>
> Signed-off-by: Alexandre Courbot <acourbot@xxxxxxxxxx>

Reviewed-by: Gary Guo <gary@xxxxxxxxxxx>

> ---
> rust/kernel/num/bounded.rs | 7 +++++--
> 1 file changed, 5 insertions(+), 2 deletions(-)