fork/rust
git clone https://git.julia.blue/fork/rust
4560ea788cb
1.39.0
1error[E0308]: mismatched types 2 --> $DIR/format-borrow.rs:2:21 3 | 4LL | let a: String = &String::from("a"); 5 | ^^^^^^^^^^^^^^^^^^ 6 | | 7 | expected struct `std::string::String`, found reference 8 | help: consider removing the borrow: `String::from("a")` 9 | 10 = note: expected type `std::string::String` 11 found type `&std::string::String` 12 13error[E0308]: mismatched types 14 --> $DIR/format-borrow.rs:4:21 15 | 16LL | let b: String = &format!("b"); 17 | ^^^^^^^^^^^^^ 18 | | 19 | expected struct `std::string::String`, found reference 20 | help: consider removing the borrow: `format!("b")` 21 | 22 = note: expected type `std::string::String` 23 found type `&std::string::String` 24 25error: aborting due to 2 previous errors 26 27For more information about this error, try `rustc --explain E0308`.