Skip to content

Commit 2b0bb59

Browse files
authored
Merge pull request #87 from derrabus/bugfix/preg-match-null-flags
Pass `0` instead of `null` to `preg_match()` `$flags`, since in PHP 8.1+ the signature may change
2 parents a81a7a0 + e661c49 commit 2b0bb59

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Scanner/DocBlockScanner.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ protected function tokenize()
176176
}
177177
$currentChar = $stream[$streamIndex];
178178
$matches = [];
179-
$currentLine = preg_match('#(.*?)\r?\n#', $stream, $matches, null, $streamIndex) === 1
179+
$currentLine = preg_match('#(.*?)\r?\n#', $stream, $matches, 0, $streamIndex) === 1
180180
? $matches[1]
181181
: substr($stream, $streamIndex);
182182
if ($currentChar === ' ') {

0 commit comments

Comments
 (0)