1
Fork 0

Rollup merge of #112790 - WaffleLapkin:syntactically, r=Nilstrieb

Syntactically accept `become` expressions (explicit tail calls experiment)

This adds `ast::ExprKind::Become`, implements parsing and properly gates the feature.

cc `@scottmcm`
This commit is contained in:
Nilstrieb 2023-06-21 07:37:02 +02:00 committed by GitHub
commit c6710d15f1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 74 additions and 2 deletions

View file

@ -569,7 +569,8 @@ impl<'v> ast_visit::Visitor<'v> for StatCollector<'v> {
Array, ConstBlock, Call, MethodCall, Tup, Binary, Unary, Lit, Cast, Type, Let,
If, While, ForLoop, Loop, Match, Closure, Block, Async, Await, TryBlock, Assign,
AssignOp, Field, Index, Range, Underscore, Path, AddrOf, Break, Continue, Ret,
InlineAsm, FormatArgs, OffsetOf, MacCall, Struct, Repeat, Paren, Try, Yield, Yeet, IncludedBytes, Err
InlineAsm, FormatArgs, OffsetOf, MacCall, Struct, Repeat, Paren, Try, Yield, Yeet,
Become, IncludedBytes, Err
]
);
ast_visit::walk_expr(self, e)