]> git.lizzy.rs Git - rust.git/blobdiff - src/test/run-pass/match-arm-statics.rs
statics in match arm: compile with -g
[rust.git] / src / test / run-pass / match-arm-statics.rs
index 43ff69fe75e6c6164c29badab6d37c21741b27ff..78a37f51837860f8d532d2c4c5032491a5ebf7bc 100644 (file)
@@ -8,19 +8,26 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: -g
 
+#[derive(PartialEq, Eq)]
 struct NewBool(bool);
 
+#[derive(PartialEq, Eq)]
 enum Direction {
     North,
     East,
     South,
     West
 }
+
+#[derive(PartialEq, Eq)]
 struct Foo {
     bar: Option<Direction>,
     baz: NewBool
 }
+
+#[derive(PartialEq, Eq)]
 enum EnumWithStructVariants {
     Variant1(bool),
     Variant2 {
@@ -37,7 +44,7 @@ enum EnumWithStructVariants {
     dir: Direction::North };
 
 pub mod glfw {
-    #[derive(Copy, Clone)]
+    #[derive(Copy, Clone, PartialEq, Eq)]
     pub struct InputState(usize);
 
     pub const RELEASE  : InputState = InputState(0);
@@ -82,6 +89,7 @@ fn issue_14576() {
         _ => unreachable!()
     }
 
+    #[derive(PartialEq, Eq)]
     enum C { D = 3, E = 4 }
     const F : C = C::D;
 
@@ -89,6 +97,7 @@ enum C { D = 3, E = 4 }
 }
 
 fn issue_13731() {
+    #[derive(PartialEq, Eq)]
     enum A { AA(()) }
     const B: A = A::AA(());
 
@@ -99,6 +108,7 @@ enum A { AA(()) }
 
 fn issue_15393() {
     #![allow(dead_code)]
+    #[derive(PartialEq, Eq)]
     struct Flags {
         bits: usize
     }