diff options
| author | Alexander Bulaev <aleks.bulaev@gmail.com> | 2015-11-12 10:40:02 +0300 |
|---|---|---|
| committer | Alexander Bulaev <aleks.bulaev@gmail.com> | 2015-11-12 10:40:02 +0300 |
| commit | 8ce9c19b5bf6259eeaa4482a824893cdf3dfe0e3 (patch) | |
| tree | 6297c626cbf30787ca664b43d437cf85f7e671d6 /src/liballoc/arc.rs | |
| parent | fcc79f2d60d55114ae890e1112393ef0e2e8d93f (diff) | |
| download | rust-8ce9c19b5bf6259eeaa4482a824893cdf3dfe0e3.tar.gz rust-8ce9c19b5bf6259eeaa4482a824893cdf3dfe0e3.zip | |
Remove impls for cases considered `niche`
Diffstat (limited to 'src/liballoc/arc.rs')
| -rw-r--r-- | src/liballoc/arc.rs | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/src/liballoc/arc.rs b/src/liballoc/arc.rs index 36f915d19e9..a2ccac3ba7e 100644 --- a/src/liballoc/arc.rs +++ b/src/liballoc/arc.rs @@ -902,16 +902,8 @@ impl<T> From<T> for Arc<T> { } } -#[stable(feature = "rust1", since = "1.6.0")] -impl<T> From<Box<T>> for Arc<T> { - fn from(t: Box<T>) -> Self { - Arc::new(*t) - } -} - #[cfg(test)] mod tests { - use std::boxed::Box; use std::clone::Clone; use std::sync::mpsc::channel; use std::mem::drop; @@ -1161,13 +1153,6 @@ mod tests { let foo_arc = Arc::from(foo); assert!(123 == *foo_arc); } - - #[test] - fn test_from_box() { - let foo_box = Box::new(123); - let foo_arc = Arc::from(foo_box); - assert!(123 == *foo_arc); - } } impl<T: ?Sized> borrow::Borrow<T> for Arc<T> { |
