Skip to content

Commit f5d8a62

Browse files
committed
Added some extra debug output
1 parent d427d75 commit f5d8a62

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/Standards/Generic/Sniffs/WhiteSpace/ScopeIndentSniff.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1017,13 +1017,14 @@ public function process(File $phpcsFile, $stackPtr)
10171017
if ($tokens[$i]['code'] === T_OPEN_SHORT_ARRAY) {
10181018
$disableExactEnd = max($disableExactEnd, $tokens[$i]['bracket_closer']);
10191019
if ($this->debug === true) {
1020-
$line = $tokens[$i]['line'];
1021-
$type = $tokens[$disableExactEnd]['type'];
1020+
$line = $tokens[$i]['line'];
1021+
$type = $tokens[$disableExactEnd]['type'];
1022+
$endLine = $tokens[$disableExactEnd]['line'];
10221023
echo "Opening short array bracket found on line $line".PHP_EOL;
10231024
if ($disableExactEnd === $tokens[$i]['bracket_closer']) {
1024-
echo "\t=> disabling exact indent checking until $disableExactEnd ($type)".PHP_EOL;
1025+
echo "\t=> disabling exact indent checking until $disableExactEnd ($type) on line $endLine".PHP_EOL;
10251026
} else {
1026-
echo "\t=> continuing to disable exact indent checking until $disableExactEnd ($type)".PHP_EOL;
1027+
echo "\t=> continuing to disable exact indent checking until $disableExactEnd ($type) on line $endLine".PHP_EOL;
10271028
}
10281029
}
10291030
}

0 commit comments

Comments
 (0)