about summary refs log tree commit diff
path: root/src/libstd
diff options
context:
space:
mode:
authorClar Charr <clar@charr.xyz>2017-03-15 01:15:27 -0400
committerClar Charr <clar@charr.xyz>2017-03-15 11:36:13 -0400
commit0739ecec618dc15332e1588a560ea449d4547d5e (patch)
tree5eb9760a0527dc688053219164496f819d6ddb19 /src/libstd
parent11a33760ecfd925be089a28c54f12a5490fd9a2f (diff)
downloadrust-0739ecec618dc15332e1588a560ea449d4547d5e.tar.gz
rust-0739ecec618dc15332e1588a560ea449d4547d5e.zip
Removes Default for Box<Path>.
Diffstat (limited to 'src/libstd')
-rw-r--r--src/libstd/path.rs14
1 files changed, 0 insertions, 14 deletions
diff --git a/src/libstd/path.rs b/src/libstd/path.rs
index 49b01bc0853..b524af800c1 100644
--- a/src/libstd/path.rs
+++ b/src/libstd/path.rs
@@ -1224,14 +1224,6 @@ impl Into<Box<Path>> for PathBuf {
     }
 }
 
-#[stable(feature = "box_default_extra", since = "1.17.0")]
-impl Default for Box<Path> {
-    fn default() -> Box<Path> {
-        let boxed: Box<OsStr> = Default::default();
-        unsafe { mem::transmute(boxed) }
-    }
-}
-
 #[stable(feature = "rust1", since = "1.0.0")]
 impl<'a, T: ?Sized + AsRef<OsStr>> From<&'a T> for PathBuf {
     fn from(s: &'a T) -> PathBuf {
@@ -3730,10 +3722,4 @@ mod tests {
         assert_eq!(&*boxed, &*path_buf);
         assert_eq!(&*path_buf, path);
     }
-
-    #[test]
-    fn boxed_default() {
-        let boxed = <Box<Path>>::default();
-        assert!(boxed.as_os_str().is_empty());
-    }
 }