]> git.lizzy.rs Git - rust.git/blobdiff - src/test/run-pass/dst-struct-sole.rs
cleanup: s/impl Copy/#[derive(Copy)]/g
[rust.git] / src / test / run-pass / dst-struct-sole.rs
index 26cb27cc653925b576e27eb874eb2dc9f28242ed..74f4b9e923301732b7786d14adae54d5601dd307 100644 (file)
@@ -10,7 +10,7 @@
 
 // As dst-struct.rs, but the unsized field is the only field in the struct.
 
-struct Fat<Sized? T> {
+struct Fat<T: ?Sized> {
     ptr: T
 }
 
@@ -30,11 +30,9 @@ fn foo2<T:ToBar>(x: &Fat<[T]>) {
     assert!(x.ptr[1].to_bar() == bar);
 }
 
-#[deriving(PartialEq,Eq)]
+#[derive(Copy, PartialEq, Eq)]
 struct Bar;
 
-impl Copy for Bar {}
-
 trait ToBar {
     fn to_bar(&self) -> Bar;
 }