rust/library/std/src/sys
Matthias Krüger 4efdb5c001
Rollup merge of #98202 - aticu:impl_tryfrom_osstr_for_str, r=Amanieu
Implement `TryFrom<&OsStr>` for `&str`

Recently when trying to work with `&OsStr` I was surprised to find this `impl` missing.

Since the `to_str` method already existed the actual implementation is fairly non-controversial, except for maybe the choice of the error type. I chose an opaque error here instead of something like `std::str::Utf8Error`, since that would already make a number of assumption about the underlying implementation of `OsStr`.

As this is a trait implementation, it is insta-stable, if I'm not mistaken?
Either way this will need an FCP.
I chose "1.64.0" as the version, since this is unlikely to land before the beta cut-off.

`@rustbot` modify labels: +T-libs-api

API Change Proposal: rust-lang/rust#99031 (accepted)
2023-06-14 18:10:27 +02:00
..
common Avoid unwind across extern "C" in thread_local::fast_local.rs 2023-06-04 14:54:28 -07:00
hermit Rollup merge of #103056 - beetrees:timespec-bug-fix, r=thomcc 2023-05-05 18:40:32 +05:30
itron Match unmatched backticks in library/ 2023-03-03 03:03:29 +01:00
sgx Improve code around SGX waitqueue 2023-05-11 11:03:07 +02:00
solid Rollup merge of #103056 - beetrees:timespec-bug-fix, r=thomcc 2023-05-05 18:40:32 +05:30
unix Rollup merge of #98202 - aticu:impl_tryfrom_osstr_for_str, r=Amanieu 2023-06-14 18:10:27 +02:00
unsupported Rollup merge of #105695 - joboet:remove_generic_parker, r=m-ou-se 2023-05-03 16:42:48 -07:00
wasi std: make internal-only items pub(crate) 2023-05-25 08:15:05 -07:00
wasm std: replace generic thread parker with explicit no-op parker 2023-02-16 15:06:45 +01:00
windows Rollup merge of #98202 - aticu:impl_tryfrom_osstr_for_str, r=Amanieu 2023-06-14 18:10:27 +02:00
mod.rs Don't force include Windows goop when documenting 2023-05-09 19:34:01 +01:00