rust/library
Matthias Krüger 904dba5066
Rollup merge of #90772 - GuillaumeGomez:vec-retain-mut, r=joshtriplett
Add Vec::retain_mut

This is to continue the discussion started in #83218.

Original comment was:

> Take 2 of #34265, since I needed this today.

The reason I think why we should add `retain_mut` is for coherency and for discoverability. For example we have `chunks` and `chunks_mut` or `get` and `get_mut` or `iter` and `iter_mut`, etc. When looking for mutable `retain`, I would expect `retain_mut` to exist. It took me a while to find out about `drain_filter`. So even if it provides an API close to `drain_filter`, just for the discoverability, I think it's worth it.

cc ``````@m-ou-se`````` ``````@jonas-schievink`````` ``````@Mark-Simulacrum``````
2021-11-17 15:58:01 +01:00
..
alloc Rollup merge of #90772 - GuillaumeGomez:vec-retain-mut, r=joshtriplett 2021-11-17 15:58:01 +01:00
backtrace@b02ed04a7e Updated backtrace submodule 2021-11-02 12:31:34 +01:00
core Rollup merge of #90687 - jhpratt:const_panic, r=oli-obk 2021-11-17 15:58:00 +01:00
panic_abort Add SOLID targets 2021-09-28 11:31:47 +09:00
panic_unwind Add SOLID targets 2021-09-28 11:31:47 +09:00
portable-simd Add 'library/portable-simd/' from commit '1ce1c645cf27c4acdefe6ec8a11d1f0491954a99' 2021-11-12 16:58:25 -08:00
proc_macro proc_macro: Add an expand_expr method to TokenStream 2021-11-12 15:41:40 -05:00
profiler_builtins rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rtstartup Bump bootstrap compiler to 1.50 beta 2020-12-30 09:27:19 -05:00
rustc-std-workspace-alloc rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc-std-workspace-core rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc-std-workspace-std rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
std Rollup merge of #90835 - sunfishcode:sunfishcode/wasi-char-device, r=alexcrichton 2021-11-16 09:14:19 +09:00
stdarch@5fdbc476af Update stdarch submodule 2021-09-21 11:24:08 +02:00
test clippy::perf fixes 2021-11-04 21:07:56 +01:00
unwind Repace use of static_nobundle with native_link_modifiers 2021-10-23 15:51:22 +02:00