Email or username:

Password:

Forgot your password?
Top-level
Asahi Linya (朝日りにゃ〜)

@argv_minus_one @raulinbonn This is solved in kernel code by disallowing those methods that abort. That was decided early on. The approach has changed a few times but fallible allocation was pretty much always banned.

2 comments
Asahi Linya (朝日りにゃ〜)

@argv_minus_one @raulinbonn The Linux kernel uses no_std. Until recently there was an internal fork of the alloc crate with those fallible constructors outright gated off. Now things are switching to custom allocators where the Box types (there are several to allow for different allocators in the kernel) are outright always fallible with the standard constructors.

lore.kernel.org/lkml/202408160

Go Up