2
0
mirror of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git synced 2025-09-04 20:19:47 +08:00
linux/rust/kernel/alloc
Alexandre Courbot 85f8e98dbb rust: alloc: allow coercion from Box<T> to Box<dyn U> if T implements U
This enables the creation of trait objects backed by a Box, similarly to
what can be done with the standard library.

Suggested-by: Benno Lossin <benno.lossin@proton.me>
Reviewed-by: Alice Ryhl <aliceryhl@google.com>
Reviewed-by: Benno Lossin <benno.lossin@proton.me>
Signed-off-by: Alexandre Courbot <acourbot@nvidia.com>
Link: https://lore.kernel.org/r/20250412-box_trait_objs-v3-1-f67ced62d520@nvidia.com
Signed-off-by: Danilo Krummrich <dakr@kernel.org>
2025-04-22 17:29:37 +02:00
..
allocator_test.rs rust: alloc: satisfy POSIX alignment requirement 2025-03-05 23:57:48 +01:00
allocator.rs rust: alloc: make ReallocFunc::call inline 2025-03-06 20:49:06 +01:00
kbox.rs rust: alloc: allow coercion from Box<T> to Box<dyn U> if T implements U 2025-04-22 17:29:37 +02:00
kvec.rs rust: alloc: use spare_capacity_mut to reduce unsafe 2025-04-07 16:59:06 +02:00
layout.rs rust: alloc: add doctest for ArrayLayout::new() 2025-01-13 23:45:30 +01:00