Files
rust/library/std/src
Dylan DPC c4dd0d3bb7 Rollup merge of #96397 - AronParker:issue-96368-fix, r=dtolnay
Make EncodeWide implement FusedIterator

[`EncodeUtf16`](https://doc.rust-lang.org/std/str/struct.EncodeUtf16.html) and [`EncodeWide`](https://doc.rust-lang.org/std/os/windows/ffi/struct.EncodeWide.html) currently serve similar purposes: They convert from UTF-8 to UTF-16 and WTF-8 to WTF-16, respectively. `EncodeUtf16` wraps a &str, whereas `EncodeWide` wraps an &OsStr.

When Iteration has concluded, these iterators wrap an empty slice, which will forever yield `None` values. Hence, `EncodeUtf16` rightfully implements `FusedIterator`. However, `EncodeWide` in contrast does not, even though it serves an almost identical purpose.

This PR attempts to fix that issue. I consider this change minor and non-controversial, hence why I have not added a RFC/FCP. Please let me know if the stability attribute is wrong or contains a wrong version number. Thanks in advance.

Fixes https://github.com/rust-lang/rust/issues/96368
2022-04-28 02:40:33 +02:00
..
2021-10-25 22:44:41 -05:00
2022-04-07 08:51:59 +01:00
2022-04-19 13:02:20 +10:00
2022-04-17 01:23:46 -04:00
2022-03-23 05:33:44 +00:00
2022-04-25 17:05:58 -07:00
2022-04-05 23:18:40 +02:00
2022-04-05 23:18:40 +02:00
2022-04-05 23:18:40 +02:00
2022-04-17 01:23:46 -04:00
2022-04-17 01:23:47 -04:00