Skip to content

Commit 504821f

Browse files
author
Kirill Nesmeyanov
committed
Fix linter issues
1 parent b2582d0 commit 504821f

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/Node/Literal/IntLiteralNode.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,14 @@ private static function split(string $literal): array
4242
{
4343
$literal = \str_replace('_', '', $literal);
4444

45-
if ($isNegative = ($literal[0] === '-')) {
45+
if ($negative = ($literal[0] === '-')) {
4646
$literal = \substr($literal, 1);
4747
}
4848

4949
// One of: [ 0123, 0o23, 0x00, 0b01 ]
5050
if ($literal[0] === '0' && isset($literal[1])) {
51-
return [$isNegative, match ($literal[1]) {
51+
/** @var array{bool, numeric-string} */
52+
return [$negative, match ($literal[1]) {
5253
// hexadecimal
5354
'x', 'X' => \base_convert(\substr($literal, 2), 16, 10),
5455
// binary
@@ -60,7 +61,8 @@ private static function split(string $literal): array
6061
}];
6162
}
6263

63-
return [$isNegative, $literal];
64+
/** @var array{bool, numeric-string} */
65+
return [$negative, $literal];
6466
}
6567

6668
public function getValue(): int

0 commit comments

Comments
 (0)