about summary refs log tree commit diff
path: root/library/std/src/path.rs
diff options
context:
space:
mode:
authorStuart Cook <Zalathar@users.noreply.github.com>2025-05-02 22:17:00 +1000
committerGitHub <noreply@github.com>2025-05-02 22:17:00 +1000
commit6fc78d410d506e3c95c6362046f3965810f5ec6d (patch)
treea8d2c7568875e20f4e0bd3b7e64c3c1984fd4924 /library/std/src/path.rs
parent192fbcc83a96a506cc08a60ec3d072e165c5e860 (diff)
parent28deaa6e0e7993f963b3bb44bb235c7682ce0cf3 (diff)
downloadrust-6fc78d410d506e3c95c6362046f3965810f5ec6d.tar.gz
rust-6fc78d410d506e3c95c6362046f3965810f5ec6d.zip
Rollup merge of #139847 - thaliaarchi:args/delegate-iter, r=workingjubilee
Delegate to inner `vec::IntoIter` from `env::ArgsOs`

Delegate from `std::env::ArgsOs` to the methods of the inner platform-specific iterators, when it would be more efficient than just using the default methods of its own impl. Most platforms use `vec::IntoIter` as the inner type, so prioritize delegating to the methods it provides.

`std::env::Args` is implemented atop `std::env::ArgsOs` and performs UTF-8 validation with a panic for invalid data. This is a visible effect which users certainly rely on, so we can't skip any arguments. Any further iterator methods would skip some elements, so no change is needed for that type.

Add `#[inline]` for any methods which simply wrap the inner iterator.
Diffstat (limited to 'library/std/src/path.rs')
0 files changed, 0 insertions, 0 deletions