1 2 3 4 5 6 7 8 9
fn test() -> impl std::fmt::Debug { if true { "boo2" } else { //~^ ERROR `if` and `else` have incompatible types } } fn main() {}