@@ -30,8 +30,8 @@ use crate::{
30
30
expander:: Expander ,
31
31
hir:: {
32
32
dummy_expr_id, Array , Binding , BindingAnnotation , BindingId , BindingProblems , CaptureBy ,
33
- ClosureKind , Expr , ExprId , Label , LabelId , Literal , LiteralOrConst , MatchArm , Movability ,
34
- OffsetOf , Pat , PatId , RecordFieldPat , RecordLitField , Statement ,
33
+ ClosureKind , Expr , ExprId , InlineAsm , Label , LabelId , Literal , LiteralOrConst , MatchArm ,
34
+ Movability , OffsetOf , Pat , PatId , RecordFieldPat , RecordLitField , Statement ,
35
35
} ,
36
36
item_scope:: BuiltinShadowMode ,
37
37
lang_item:: LangItem ,
@@ -648,7 +648,10 @@ impl ExprCollector<'_> {
648
648
}
649
649
}
650
650
ast:: Expr :: UnderscoreExpr ( _) => self . alloc_expr ( Expr :: Underscore , syntax_ptr) ,
651
- ast:: Expr :: AsmExpr ( _) => self . missing_expr ( ) ,
651
+ ast:: Expr :: AsmExpr ( e) => {
652
+ let expr = Expr :: InlineAsm ( InlineAsm { e : self . collect_expr_opt ( e. expr ( ) ) } ) ;
653
+ self . alloc_expr ( expr, syntax_ptr)
654
+ }
652
655
ast:: Expr :: OffsetOfExpr ( e) => {
653
656
let container = Interned :: new ( TypeRef :: from_ast_opt ( & self . ctx ( ) , e. ty ( ) ) ) ;
654
657
let fields = e. fields ( ) . map ( |it| it. as_name ( ) ) . collect ( ) ;
0 commit comments