Skip to content

Commit 0fb8379

Browse files
committed
std: Remove plattform-specific code from os_str
1 parent d311079 commit 0fb8379

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

src/libstd/ffi/os_str.rs

-11
Original file line numberDiff line numberDiff line change
@@ -53,17 +53,6 @@ impl OsString {
5353
OsString { inner: Buf::from_string(String::new()) }
5454
}
5555

56-
#[cfg(unix)]
57-
fn _from_bytes(vec: Vec<u8>) -> Option<OsString> {
58-
use os::unix::ffi::OsStringExt;
59-
Some(OsString::from_vec(vec))
60-
}
61-
62-
#[cfg(windows)]
63-
fn _from_bytes(vec: Vec<u8>) -> Option<OsString> {
64-
String::from_utf8(vec).ok().map(OsString::from)
65-
}
66-
6756
/// Converts to an `OsStr` slice.
6857
#[stable(feature = "rust1", since = "1.0.0")]
6958
pub fn as_os_str(&self) -> &OsStr {

0 commit comments

Comments
 (0)