summaryrefslogtreecommitdiffstats
path: root/src/test/ui/suggestions/match-ergonomics.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/suggestions/match-ergonomics.rs')
-rw-r--r--src/test/ui/suggestions/match-ergonomics.rs41
1 files changed, 0 insertions, 41 deletions
diff --git a/src/test/ui/suggestions/match-ergonomics.rs b/src/test/ui/suggestions/match-ergonomics.rs
deleted file mode 100644
index c4fc01469..000000000
--- a/src/test/ui/suggestions/match-ergonomics.rs
+++ /dev/null
@@ -1,41 +0,0 @@
-fn main() {
- let x = vec![1i32];
- match &x[..] {
- [&v] => {}, //~ ERROR mismatched types
- _ => {},
- }
- match x {
- [&v] => {}, //~ ERROR expected an array or slice
- _ => {},
- }
- match &x[..] {
- [v] => {},
- _ => {},
- }
- match &x[..] {
- &[v] => {},
- _ => {},
- }
- match x {
- [v] => {}, //~ ERROR expected an array or slice
- _ => {},
- }
- let y = 1i32;
- match &y {
- &v => {},
- _ => {},
- }
- match y {
- &v => {}, //~ ERROR mismatched types
- _ => {},
- }
- match &y {
- v => {},
- _ => {},
- }
- match y {
- v => {},
- _ => {},
- }
- if let [&v] = &x[..] {} //~ ERROR mismatched types
-}