]> git.lizzy.rs Git - rust.git/blobdiff - src/test/run-pass/empty-tag.rs
auto merge of #19514 : jbranchaud/rust/add-btree-set-bitor, r=Gankro
[rust.git] / src / test / run-pass / empty-tag.rs
index a8822e9a3fcfd1c791807642d191162806706aa7..e5d11ac1adb2aeebfe2863c9be7701c1c20af482 100644 (file)
@@ -8,9 +8,12 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+#[deriving(Show)]
 enum chan { chan_t, }
 
-impl cmp::Eq for chan {
+impl Copy for chan {}
+
+impl PartialEq for chan {
     fn eq(&self, other: &chan) -> bool {
         ((*self) as uint) == ((*other) as uint)
     }
@@ -18,10 +21,10 @@ fn ne(&self, other: &chan) -> bool { !(*self).eq(other) }
 }
 
 fn wrapper3(i: chan) {
-    assert_eq!(i, chan_t);
+    assert_eq!(i, chan::chan_t);
 }
 
 pub fn main() {
-    let wrapped = {||wrapper3(chan_t)};
+    let wrapped = {||wrapper3(chan::chan_t)};
     wrapped();
 }