@@ -124,6 +124,9 @@ macro_rules! impl_for_for_stmt {
124
124
ForHead :: UsingDecl ( ..) => {
125
125
unreachable!( "using declaration must be removed by previous pass" )
126
126
}
127
+
128
+ #[ cfg( feature = "unknown" ) ]
129
+ _ => panic!( "unable to access unknown nodes" ) ,
127
130
} ;
128
131
129
132
for_stmt. left = left;
@@ -420,6 +423,8 @@ impl AssignFolder {
420
423
"Object rest pattern should be removed by es2018::object_rest_spread \
421
424
pass"
422
425
) ,
426
+ #[ cfg( feature = "unknown" ) ]
427
+ _ => panic ! ( "unable to access unknown nodes" ) ,
423
428
}
424
429
}
425
430
}
@@ -520,6 +525,8 @@ impl Destructuring {
520
525
}
521
526
Pat :: Rest ( ..) | Pat :: Expr ( ..) => params. push ( param) ,
522
527
Pat :: Invalid ( ..) => { }
528
+ #[ cfg( feature = "unknown" ) ]
529
+ _ => panic ! ( "unable to access unknown nodes" ) ,
523
530
}
524
531
}
525
532
@@ -1004,6 +1011,8 @@ impl VisitMut for AssignFolder {
1004
1011
"object rest pattern should be removed by \
1005
1012
es2018::object_rest_spread pass"
1006
1013
) ,
1014
+ #[ cfg( feature = "unknown" ) ]
1015
+ _ => panic ! ( "unable to access unknown nodes" ) ,
1007
1016
}
1008
1017
}
1009
1018
@@ -1018,6 +1027,8 @@ impl VisitMut for AssignFolder {
1018
1027
}
1019
1028
1020
1029
AssignTargetPat :: Invalid ( ..) => unreachable ! ( ) ,
1030
+ #[ cfg( feature = "unknown" ) ]
1031
+ _ => panic ! ( "unable to access unknown nodes" ) ,
1021
1032
}
1022
1033
} ;
1023
1034
}
@@ -1295,6 +1306,8 @@ fn can_be_null(e: &Expr) -> bool {
1295
1306
| Expr :: TsSatisfies ( TsSatisfiesExpr { ref expr, .. } ) => can_be_null ( expr) ,
1296
1307
1297
1308
Expr :: Invalid ( ..) => unreachable ! ( ) ,
1309
+ #[ cfg( feature = "unknown" ) ]
1310
+ _ => panic ! ( "unable to access unknown nodes" ) ,
1298
1311
}
1299
1312
}
1300
1313
0 commit comments