1 error[E0308]: mismatched types
2 --> $DIR/format-borrow.rs:2:21
4 LL | let a: String = &String::from("a");
7 | expected struct `std::string::String`, found reference
8 | help: consider removing the borrow: `String::from("a")`
10 = note: expected type `std::string::String`
11 found type `&std::string::String`
13 error[E0308]: mismatched types
14 --> $DIR/format-borrow.rs:4:21
16 LL | let b: String = &format!("b");
19 | expected struct `std::string::String`, found reference
20 | help: consider removing the borrow: `format!("b")`
22 = note: expected type `std::string::String`
23 found type `&std::string::String`
25 error: aborting due to 2 previous errors
27 For more information about this error, try `rustc --explain E0308`.