Remove the clone function for the method
This commit is contained in:
parent
f2125434d8
commit
ff28bb7839
1 changed files with 2 additions and 5 deletions
|
@ -123,6 +123,7 @@ pub impl<T:Const+Owned> ARC<T> {
|
||||||
unsafe { &*self.x.get_immut() }
|
unsafe { &*self.x.get_immut() }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Duplicate an atomically reference counted wrapper.
|
* Duplicate an atomically reference counted wrapper.
|
||||||
*
|
*
|
||||||
|
@ -130,13 +131,9 @@ pub impl<T:Const+Owned> ARC<T> {
|
||||||
* object. However, one of the `arc` objects can be sent to another task,
|
* object. However, one of the `arc` objects can be sent to another task,
|
||||||
* allowing them to share the underlying data.
|
* allowing them to share the underlying data.
|
||||||
*/
|
*/
|
||||||
pub fn clone<T:Const + Owned>(rc: &ARC<T>) -> ARC<T> {
|
|
||||||
ARC { x: rc.x.clone() }
|
|
||||||
}
|
|
||||||
|
|
||||||
impl<T:Const + Owned> Clone for ARC<T> {
|
impl<T:Const + Owned> Clone for ARC<T> {
|
||||||
fn clone(&self) -> ARC<T> {
|
fn clone(&self) -> ARC<T> {
|
||||||
clone(self)
|
ARC { x: self.x.clone() }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue