Merge pull request #7296 from smores56/proper-try-keyword

Proper `try` keyword
This commit is contained in:
Sam Mohr 2024-12-05 01:38:22 -08:00 committed by GitHub
commit 193c23bac8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
33 changed files with 1036 additions and 521 deletions

View file

@ -727,6 +727,7 @@ impl<'a> Normalize<'a> for Expr<'a> {
arena.alloc(b.normalize(arena)),
),
Expr::Try => Expr::Try,
Expr::LowLevelTry(a) => Expr::LowLevelTry(arena.alloc(a.normalize(arena))),
Expr::Return(a, b) => Expr::Return(
arena.alloc(a.normalize(arena)),
b.map(|loc_b| &*arena.alloc(loc_b.normalize(arena))),