Skip to content
This repository was archived by the owner on Dec 1, 2023. It is now read-only.

Commit 9800ee0

Browse files
author
Jethro Beekman
committed
Make rustc-serialize fully portable
1 parent 71b8d6e commit 9800ee0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/serialize.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1356,7 +1356,7 @@ array! {
13561356
}
13571357

13581358
impl Encodable for path::Path {
1359-
#[cfg(target_os = "redox")]
1359+
#[cfg(not(any(unix, windows)))]
13601360
fn encode<S: Encoder>(&self, e: &mut S) -> Result<(), S::Error> {
13611361
self.as_os_str().to_str().unwrap().encode(e)
13621362
}
@@ -1380,7 +1380,7 @@ impl Encodable for path::PathBuf {
13801380
}
13811381

13821382
impl Decodable for path::PathBuf {
1383-
#[cfg(target_os = "redox")]
1383+
#[cfg(not(any(unix, windows)))]
13841384
fn decode<D: Decoder>(d: &mut D) -> Result<path::PathBuf, D::Error> {
13851385
let string: String = try!(Decodable::decode(d));
13861386
let s: OsString = OsString::from(string);

0 commit comments

Comments
 (0)