]> git.lizzy.rs Git - rust.git/blobdiff - src/test/run-pass/tuple-struct-constructor-pointer.rs
cleanup: s/impl Copy/#[derive(Copy)]/g
[rust.git] / src / test / run-pass / tuple-struct-constructor-pointer.rs
index dbb5db649ef31dd59ccc9057fc72faa3cb7bf529..a4bb914b1ab3dc674e973fbad9295b6c3a2594e9 100644 (file)
@@ -8,14 +8,14 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#[deriving(Eq)]
+#[derive(PartialEq, Show)]
 struct Foo(int);
-#[deriving(Eq)]
+#[derive(PartialEq, Show)]
 struct Bar(int, int);
 
-fn main() {
-    let f: extern fn(int) -> Foo = Foo;
-    let g: extern fn(int, int) -> Bar = Bar;
+pub fn main() {
+    let f: fn(int) -> Foo = Foo;
+    let g: fn(int, int) -> Bar = Bar;
     assert_eq!(f(42), Foo(42));
     assert_eq!(g(4, 7), Bar(4, 7));
 }