@@ -1122,7 +1122,7 @@ public function process(File $phpcsFile, $stackPtr)
1122
1122
if ($ this ->debug === true ) {
1123
1123
$ type = str_replace ('_ ' , ' ' , strtolower (substr ($ tokens [$ i ]['type ' ], 2 )));
1124
1124
$ line = $ tokens [$ i ]['line ' ];
1125
- echo "* ignoring single-line $ type on line $ line " .PHP_EOL ;
1125
+ echo "* ignoring single-line $ type on line $ line * " .PHP_EOL ;
1126
1126
}
1127
1127
1128
1128
$ i = $ closer ;
@@ -1192,14 +1192,24 @@ public function process(File $phpcsFile, $stackPtr)
1192
1192
if ($ this ->debug === true ) {
1193
1193
$ line = $ tokens [$ i ]['line ' ];
1194
1194
$ type = $ tokens [$ i ]['type ' ];
1195
- echo "* ignoring single-line $ type on line $ line " .PHP_EOL ;
1195
+ echo "* ignoring single-line $ type on line $ line * " .PHP_EOL ;
1196
1196
}
1197
1197
1198
1198
$ i = $ closer ;
1199
1199
continue ;
1200
1200
}
1201
1201
1202
1202
$ condition = $ tokens [$ tokens [$ i ]['scope_condition ' ]]['code ' ];
1203
+ if ($ condition === T_FN ) {
1204
+ if ($ this ->debug === true ) {
1205
+ $ line = $ tokens [$ tokens [$ i ]['scope_condition ' ]]['line ' ];
1206
+ echo "* ignoring arrow function on line $ line * " .PHP_EOL ;
1207
+ }
1208
+
1209
+ $ i = $ closer ;
1210
+ continue ;
1211
+ }
1212
+
1203
1213
if (isset (Tokens::$ scopeOpeners [$ condition ]) === true
1204
1214
&& in_array ($ condition , $ this ->nonIndentingScopes , true ) === false
1205
1215
) {
@@ -1239,7 +1249,7 @@ public function process(File $phpcsFile, $stackPtr)
1239
1249
if ($ tokens [$ i ]['line ' ] === $ tokens [$ closer ]['line ' ]) {
1240
1250
if ($ this ->debug === true ) {
1241
1251
$ line = $ tokens [$ i ]['line ' ];
1242
- echo "* ignoring single-line JS object on line $ line " .PHP_EOL ;
1252
+ echo "* ignoring single-line JS object on line $ line * " .PHP_EOL ;
1243
1253
}
1244
1254
1245
1255
$ i = $ closer ;
0 commit comments