@@ -410,7 +410,7 @@ impl<'a> Fold for Hoist<'a> {
410410 if let Expr :: Member ( member) = & * * init {
411411 // Match var x = require('foo').bar;
412412 if let Some ( source) =
413- match_require ( & * member. obj , & self . collect . decls , self . collect . ignore_mark )
413+ match_require ( & member. obj , & self . collect . decls , self . collect . ignore_mark )
414414 {
415415 if !self . collect . non_static_requires . contains ( & source) {
416416 // If this is not the first declarator in the variable declaration, we need to
@@ -742,7 +742,7 @@ impl<'a> Fold for Hoist<'a> {
742742 . enumerate ( )
743743 . map ( |( i, expr) | {
744744 if i != len - 1
745- && match_require ( & * expr, & self . collect . decls , self . collect . ignore_mark ) . is_some ( )
745+ && match_require ( & expr, & self . collect . decls , self . collect . ignore_mark ) . is_some ( )
746746 {
747747 return Box :: new ( Expr :: Unary ( UnaryExpr {
748748 op : UnaryOp :: Bang ,
@@ -1346,7 +1346,7 @@ impl Visit for Collect {
13461346 }
13471347 Stmt :: Expr ( expr) => {
13481348 // Top-level require(). Do not traverse further so it is not marked as wrapped.
1349- if let Some ( _source) = self . match_require ( & * expr. expr ) {
1349+ if let Some ( _source) = self . match_require ( & expr. expr ) {
13501350 return ;
13511351 }
13521352
@@ -1844,7 +1844,7 @@ impl Visit for Collect {
18441844
18451845 match & * * init {
18461846 Expr :: Member ( member) => {
1847- if let Some ( source) = self . match_require ( & * member. obj ) {
1847+ if let Some ( source) = self . match_require ( & member. obj ) {
18481848 // Convert member expression on require to a destructuring assignment.
18491849 // const yx = require('y').x; -> const {x: yx} = require('x');
18501850 let key = match & member. prop {
@@ -1875,7 +1875,7 @@ impl Visit for Collect {
18751875 Expr :: Await ( await_exp) => {
18761876 // let x = await import('foo');
18771877 // let {x} = await import('foo');
1878- if let Some ( source) = match_import ( & * await_exp. arg , self . ignore_mark ) {
1878+ if let Some ( source) = match_import ( & await_exp. arg , self . ignore_mark ) {
18791879 self . add_pat_imports ( & node. name , & source, ImportKind :: DynamicImport ) ;
18801880 return ;
18811881 }
@@ -1903,7 +1903,7 @@ impl Visit for Collect {
19031903 }
19041904 Expr :: Member ( member) => {
19051905 // import('foo').then(foo => ...);
1906- if let Some ( source) = match_import ( & * member. obj , self . ignore_mark ) {
1906+ if let Some ( source) = match_import ( & member. obj , self . ignore_mark ) {
19071907 if match_property_name ( member) . map_or ( false , |f| & * f. 0 == "then" ) {
19081908 if let Some ( ExprOrSpread { expr, .. } ) = node. args . get ( 0 ) {
19091909 let param = match & * * expr {
@@ -2078,15 +2078,15 @@ impl Collect {
20782078 for prop in & object. props {
20792079 match prop {
20802080 ObjectPatProp :: KeyValue ( kv) => {
2081- self . get_non_const_binding_idents ( & * kv. value , idents) ;
2081+ self . get_non_const_binding_idents ( & kv. value , idents) ;
20822082 }
20832083 ObjectPatProp :: Assign ( assign) => {
20842084 if self . non_const_bindings . contains_key ( & id ! ( assign. key) ) {
20852085 idents. push ( assign. key . clone ( ) ) ;
20862086 }
20872087 }
20882088 ObjectPatProp :: Rest ( rest) => {
2089- self . get_non_const_binding_idents ( & * rest. arg , idents) ;
2089+ self . get_non_const_binding_idents ( & rest. arg , idents) ;
20902090 }
20912091 }
20922092 }
@@ -2121,7 +2121,7 @@ fn has_binding_identifier(node: &Pat, sym: &JsWord, decls: &HashSet<Id>) -> bool
21212121 for prop in & object. props {
21222122 match prop {
21232123 ObjectPatProp :: KeyValue ( kv) => {
2124- if has_binding_identifier ( & * kv. value , sym, decls) {
2124+ if has_binding_identifier ( & kv. value , sym, decls) {
21252125 return true ;
21262126 }
21272127 }
@@ -2131,7 +2131,7 @@ fn has_binding_identifier(node: &Pat, sym: &JsWord, decls: &HashSet<Id>) -> bool
21312131 }
21322132 }
21332133 ObjectPatProp :: Rest ( rest) => {
2134- if has_binding_identifier ( & * rest. arg , sym, decls) {
2134+ if has_binding_identifier ( & rest. arg , sym, decls) {
21352135 return true ;
21362136 }
21372137 }
0 commit comments