Skip to content

Commit b349baa

Browse files
committed
Auto merge of rust-lang#17668 - Veykril:incorrect-nevers, r=Veykril
Remove incorrect never! invocations These can crop up when the `Future` related lang items are missing
2 parents 64cb0bf + c00246f commit b349baa

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

src/tools/rust-analyzer/crates/hir/src/display.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,9 +134,9 @@ impl HirDisplay for Function {
134134
.as_ref()
135135
.unwrap()
136136
}
137-
_ => panic!("Async fn ret_type should be impl Future"),
137+
_ => &TypeRef::Error,
138138
},
139-
_ => panic!("Async fn ret_type should be impl Future"),
139+
_ => &TypeRef::Error,
140140
}
141141
};
142142

src/tools/rust-analyzer/crates/hir/src/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1977,7 +1977,6 @@ impl Function {
19771977
return Type::new_with_resolver_inner(db, &resolver, output_eq.ty).into();
19781978
}
19791979
}
1980-
never!("Async fn ret_type should be impl Future");
19811980
None
19821981
}
19831982

0 commit comments

Comments
 (0)