From cc4e0186ac005768ebede5b6b858b223c33e4de3 Mon Sep 17 00:00:00 2001 From: John Clements Date: Thu, 18 Apr 2013 15:49:28 -0700 Subject: [PATCH] added test case for issue 5927 --- src/test/run-fail/issue-5927.rs | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 src/test/run-fail/issue-5927.rs diff --git a/src/test/run-fail/issue-5927.rs b/src/test/run-fail/issue-5927.rs new file mode 100644 index 000000000000..f302d706c15d --- /dev/null +++ b/src/test/run-fail/issue-5927.rs @@ -0,0 +1,20 @@ +// Copyright 2013 The Rust Project Developers. See the COPYRIGHT +// file at the top-level directory of this distribution and at +// http://rust-lang.org/COPYRIGHT. +// +// Licensed under the Apache License, Version 2.0 or the MIT license +// , at your +// option. This file may not be copied, modified, or distributed +// except according to those terms. + + + +// error-pattern:cant-use-x-as-pattern-mumble + +fn main() { + let z = match 3 { + x() => x + }; + assert_eq!(z,3); +}