@@ -77,8 +77,8 @@ impl<'a, 'b> SimpleArgument<'a, 'b> {
7777 Expression :: TaggedTemplateExpression ( template) => {
7878 is_simple_template_literal ( & template. quasi , depth + 1 )
7979 }
80- Expression :: ObjectExpression ( object) => self . is_simple_object ( object, depth) ,
81- Expression :: ArrayExpression ( array) => self . is_simple_array ( array, depth) ,
80+ Expression :: ObjectExpression ( object) => Self :: is_simple_object ( object, depth) ,
81+ Expression :: ArrayExpression ( array) => Self :: is_simple_array ( array, depth) ,
8282 Expression :: UnaryExpression ( unary_expression) => {
8383 matches ! (
8484 unary_expression. operator,
@@ -102,14 +102,14 @@ impl<'a, 'b> SimpleArgument<'a, 'b> {
102102 && Self :: from ( & computed_expression. object ) . is_simple_impl ( depth)
103103 }
104104 Expression :: NewExpression ( expr) => {
105- self . is_simple_call_like ( & expr. callee , & expr. arguments , depth)
105+ Self :: is_simple_call_like ( & expr. callee , & expr. arguments , depth)
106106 }
107107 Expression :: CallExpression ( expr) => {
108- self . is_simple_call_like ( & expr. callee , & expr. arguments , depth)
108+ Self :: is_simple_call_like ( & expr. callee , & expr. arguments , depth)
109109 }
110110 Expression :: ImportExpression ( expr) => depth < 2 && expr. options . is_none ( ) ,
111111 Expression :: ChainExpression ( chain) => {
112- self . is_simple_chain_element ( & chain. expression , depth)
112+ Self :: is_simple_chain_element ( & chain. expression , depth)
113113 }
114114 _ => false ,
115115 } ,
@@ -119,7 +119,7 @@ impl<'a, 'b> SimpleArgument<'a, 'b> {
119119 }
120120
121121 #[ inline]
122- fn is_simple_object ( & self , object : & ' b ObjectExpression < ' a > , depth : u8 ) -> bool {
122+ fn is_simple_object ( object : & ' b ObjectExpression < ' a > , depth : u8 ) -> bool {
123123 object. properties . iter ( ) . all ( |member| {
124124 if let ObjectPropertyKind :: ObjectProperty ( property) = member {
125125 if property. method {
@@ -138,7 +138,7 @@ impl<'a, 'b> SimpleArgument<'a, 'b> {
138138 }
139139
140140 #[ inline]
141- fn is_simple_array ( & self , array : & ' b ArrayExpression < ' a > , depth : u8 ) -> bool {
141+ fn is_simple_array ( array : & ' b ArrayExpression < ' a > , depth : u8 ) -> bool {
142142 array. elements . iter ( ) . all ( |element| match element {
143143 match_expression ! ( ArrayExpressionElement ) => {
144144 Self :: from ( element. to_expression ( ) ) . is_simple_impl ( depth + 1 )
@@ -150,7 +150,6 @@ impl<'a, 'b> SimpleArgument<'a, 'b> {
150150
151151 #[ inline]
152152 fn is_simple_call_like (
153- & self ,
154153 callee : & ' b Expression < ' a > ,
155154 arguments : & ' b [ Argument < ' a > ] ,
156155 depth : u8 ,
@@ -161,10 +160,10 @@ impl<'a, 'b> SimpleArgument<'a, 'b> {
161160 }
162161
163162 #[ inline]
164- fn is_simple_chain_element ( & self , element : & ' b ChainElement < ' a > , depth : u8 ) -> bool {
163+ fn is_simple_chain_element ( element : & ' b ChainElement < ' a > , depth : u8 ) -> bool {
165164 match element {
166165 ChainElement :: CallExpression ( call) => {
167- self . is_simple_call_like ( & call. callee , & call. arguments , depth)
166+ Self :: is_simple_call_like ( & call. callee , & call. arguments , depth)
168167 }
169168 ChainElement :: TSNonNullExpression ( assertion) => {
170169 Self :: from ( & assertion. expression ) . is_simple_impl ( depth)
0 commit comments