Skip to content

Commit 425ed6a

Browse files
authored
Update crates/hir-ty/src/infer/expr.rs
1 parent 39a653f commit 425ed6a

File tree

1 file changed

+1
-0
lines changed
  • src/tools/rust-analyzer/crates/hir-ty/src/infer

1 file changed

+1
-0
lines changed

src/tools/rust-analyzer/crates/hir-ty/src/infer/expr.rs

+1
Original file line numberDiff line numberDiff line change
@@ -933,6 +933,7 @@ impl InferenceContext<'_> {
933933
let prev_ret_coercion =
934934
mem::replace(&mut self.return_coercion, Some(CoerceMany::new(ret_ty.clone())));
935935

936+
// FIXME: We should handle async blocks like we handle closures
936937
let expected = &Expectation::has_type(ret_ty);
937938
let (_, inner_ty) = self.with_breakable_ctx(BreakableKind::Border, None, None, |this| {
938939
let ty = this.infer_block(tgt_expr, *id, statements, *tail, None, expected);

0 commit comments

Comments
 (0)