diff options
Diffstat (limited to 'src/test/ui/borrowck/issue-51415.rs')
-rw-r--r-- | src/test/ui/borrowck/issue-51415.rs | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/src/test/ui/borrowck/issue-51415.rs b/src/test/ui/borrowck/issue-51415.rs deleted file mode 100644 index f031308fb..000000000 --- a/src/test/ui/borrowck/issue-51415.rs +++ /dev/null @@ -1,11 +0,0 @@ -// Regression test for #51415: match default bindings were failing to -// see the "move out" implied by `&s` below. - -fn main() { - let a = vec![String::from("a")]; - let opt = a.iter().enumerate().find(|(_, &s)| { - //~^ ERROR cannot move out - *s == String::from("d") - }).map(|(i, _)| i); - println!("{:?}", opt); -} |