1
Fork 0

Tighten spans for async blocks

This commit is contained in:
Michael Goulet 2024-06-27 14:56:57 -04:00
parent 036b38ced3
commit 789ee88bd0
43 changed files with 173 additions and 204 deletions

View file

@ -1454,7 +1454,10 @@ pub enum ExprKind {
Block(P<Block>, Option<Label>),
/// An `async` block (`async move { ... }`),
/// or a `gen` block (`gen move { ... }`)
Gen(CaptureBy, P<Block>, GenBlockKind),
///
/// The span is the "decl", which is the header before the body `{ }`
/// including the `asyng`/`gen` keywords and possibly `move`.
Gen(CaptureBy, P<Block>, GenBlockKind, Span),
/// An await expression (`my_future.await`). Span is of await keyword.
Await(P<Expr>, Span),