]> git.lizzy.rs Git - rust.git/commitdiff
Remove test of two-phase borrows in match
authorMatthew Jasper <mjjasper1@gmail.com>
Sun, 24 Feb 2019 08:16:21 +0000 (08:16 +0000)
committerMatthew Jasper <mjjasper1@gmail.com>
Sun, 24 Feb 2019 08:16:21 +0000 (08:16 +0000)
tests/run-pass/2phase.rs

index 987adca477a6fce79b300f97c6757c17b764eef0..5ca0ff5d8df86ed68525be7288aab599fd3bb950 100644 (file)
@@ -43,14 +43,6 @@ fn two_phase_overlapping2() {
 }
 */
 
-fn match_two_phase() {
-    let mut x = 3;
-    match x {
-        ref mut y if { let _val = x; let _val = *y; true } => {},
-        _ => (),
-    }
-}
-
 fn with_interior_mutability() {
     use std::cell::Cell;
 
@@ -76,7 +68,6 @@ fn main() {
     two_phase2();
     two_phase3(false);
     two_phase3(true);
-    match_two_phase();
     with_interior_mutability();
     //FIXME: enable these, or remove them, depending on how https://github.com/rust-lang/rust/issues/56254 gets resolved
     //two_phase_overlapping1();