2017-06-23 17:43:35 -07:00
|
|
|
error[E0308]: mismatched types
|
|
|
|
--> $DIR/consider-removing-last-semi.rs:11:18
|
|
|
|
|
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | fn f() -> String { //~ ERROR mismatched types
|
2017-06-23 17:43:35 -07:00
|
|
|
| __________________^
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | | 0u8;
|
|
|
|
LL | | "bla".to_string();
|
2017-06-24 01:09:57 -07:00
|
|
|
| | - help: consider removing this semicolon
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | | }
|
2017-06-23 17:43:35 -07:00
|
|
|
| |_^ expected struct `std::string::String`, found ()
|
|
|
|
|
|
|
|
|
= note: expected type `std::string::String`
|
|
|
|
found type `()`
|
|
|
|
|
|
|
|
error[E0308]: mismatched types
|
|
|
|
--> $DIR/consider-removing-last-semi.rs:16:18
|
|
|
|
|
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | fn g() -> String { //~ ERROR mismatched types
|
2017-06-23 17:43:35 -07:00
|
|
|
| __________________^
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | | "this won't work".to_string();
|
|
|
|
LL | | "removeme".to_string();
|
2017-06-24 01:09:57 -07:00
|
|
|
| | - help: consider removing this semicolon
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | | }
|
2017-06-23 17:43:35 -07:00
|
|
|
| |_^ expected struct `std::string::String`, found ()
|
|
|
|
|
|
|
|
|
= note: expected type `std::string::String`
|
|
|
|
found type `()`
|
|
|
|
|
2017-07-02 16:09:09 +03:00
|
|
|
error: aborting due to 2 previous errors
|
2017-06-23 17:43:35 -07:00
|
|
|
|
2018-02-19 21:40:25 +01:00
|
|
|
If you want more information on this error, try using "rustc --explain E0308"
|