We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d8951ee commit 4676b10Copy full SHA for 4676b10
src/libcore/cell.rs
@@ -1512,16 +1512,14 @@ impl<T: ?Sized> UnsafeCell<T> {
1512
}
1513
1514
1515
-// TODO: correct stable attribute
1516
-#[stable(feature = "rust1", since = "1.0.0")]
1517
-impl<T: Clone> Clone for UnsafeCell<T> {
+#[stable(feature = "unsafe_cell_copy_clone_conservative", since = "1.31.0")]
+impl<T: Clone + Copy> Clone for UnsafeCell<T> {
1518
fn clone(&self) -> UnsafeCell<T> {
1519
UnsafeCell::new(self.value.clone())
1520
1521
1522
1523
1524
1525
impl<T: Copy> Copy for UnsafeCell<T> {}
1526
1527
#[stable(feature = "unsafe_cell_default", since = "1.10.0")]
0 commit comments