aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/rustdoc_test_builder.rs
diff options
context:
space:
mode:
authorAlice Ryhl <[email protected]>2025-05-02 13:19:33 +0000
committerDanilo Krummrich <[email protected]>2025-05-07 16:39:39 +0000
commit9f140894e72735f034fdc0e963d0550ef03c6f44 (patch)
tree9f33028f39182e54e328160dc764c842ba63de1f /scripts/rustdoc_test_builder.rs
parentrust: alloc: add Vec::drain_all (diff)
downloadkernel-9f140894e72735f034fdc0e963d0550ef03c6f44.tar.gz
kernel-9f140894e72735f034fdc0e963d0550ef03c6f44.zip
rust: alloc: add Vec::retain
This adds a common Vec method called `retain` that removes all elements that don't match a certain condition. Rust Binder uses it to find all processes that match a given pid. The stdlib retain method takes &T rather than &mut T and has a separate retain_mut for the &mut T case. However, this is considered an API mistake that can't be fixed now due to backwards compatibility. There's no reason for us to repeat that mistake. Signed-off-by: Alice Ryhl <[email protected]> Reviewed-by: Greg Kroah-Hartman <[email protected]> Reviewed-by: Benno Lossin <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danilo Krummrich <[email protected]>
Diffstat (limited to 'scripts/rustdoc_test_builder.rs')
0 files changed, 0 insertions, 0 deletions