]> git.lizzy.rs Git - rust.git/blob - tests/ui/issues/issue-53348.rs
Rollup merge of #107152 - GuillaumeGomez:migrate-to-css-var, r=notriddle
[rust.git] / tests / ui / issues / issue-53348.rs
1 fn main() {
2     let mut v = vec!["hello", "this", "is", "a", "test"];
3
4     let v2 = Vec::new();
5
6     v.into_iter().map(|s|s.to_owned()).collect::<Vec<_>>();
7
8     let mut a = String::new(); //~ NOTE expected due to this value
9     for i in v {
10         a = *i.to_string();
11         //~^ ERROR mismatched types
12         //~| NOTE expected struct `String`, found `str`
13         v2.push(a);
14     }
15 }