summaryrefslogtreecommitdiffstats
path: root/tests/ui/binding/fat-arrow-match.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/binding/fat-arrow-match.rs')
-rw-r--r--tests/ui/binding/fat-arrow-match.rs17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/ui/binding/fat-arrow-match.rs b/tests/ui/binding/fat-arrow-match.rs
new file mode 100644
index 000000000..aaf5be8cf
--- /dev/null
+++ b/tests/ui/binding/fat-arrow-match.rs
@@ -0,0 +1,17 @@
+// run-pass
+#![allow(dead_code)]
+#![allow(non_camel_case_types)]
+
+enum color {
+ red,
+ green,
+ blue
+}
+
+pub fn main() {
+ println!("{}", match color::red {
+ color::red => { 1 }
+ color::green => { 2 }
+ color::blue => { 3 }
+ });
+}