diff options
Diffstat (limited to 'tests/ui/structs-enums/unit-like-struct.rs')
-rw-r--r-- | tests/ui/structs-enums/unit-like-struct.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/ui/structs-enums/unit-like-struct.rs b/tests/ui/structs-enums/unit-like-struct.rs new file mode 100644 index 000000000..636ec9926 --- /dev/null +++ b/tests/ui/structs-enums/unit-like-struct.rs @@ -0,0 +1,9 @@ +// run-pass +struct Foo; + +pub fn main() { + let x: Foo = Foo; + match x { + Foo => { println!("hi"); } + } +} |