2014-04-10 04:42:25 +08:00
|
|
|
// Regression test for #13428
|
|
|
|
|
2016-10-26 02:28:20 +03:00
|
|
|
fn foo() -> String { //~ ERROR mismatched types
|
2014-05-27 20:44:58 -07:00
|
|
|
format!("Hello {}",
|
|
|
|
"world")
|
2014-04-10 04:42:25 +08:00
|
|
|
// Put the trailing semicolon on its own line to test that the
|
|
|
|
// note message gets the offending semicolon exactly
|
2017-12-10 23:29:24 +03:00
|
|
|
;
|
2014-04-10 04:42:25 +08:00
|
|
|
}
|
|
|
|
|
2016-10-26 02:28:20 +03:00
|
|
|
fn bar() -> String { //~ ERROR mismatched types
|
2014-05-25 03:17:19 -07:00
|
|
|
"foobar".to_string()
|
2017-12-10 23:29:24 +03:00
|
|
|
;
|
2014-04-10 04:42:25 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
pub fn main() {}
|