restor 3rd party comparison strict, might be relevant

This commit is contained in:
Tomas Votruba 2018-10-15 21:52:08 +08:00
parent ba0c3eea95
commit e731e46541

View File

@ -111,7 +111,7 @@ final class EregToPcreTransformer
if ($s[$i] === '[' &&
$i + 1 < $l && strpos('.=:', $s[$i + 1]) !== false) {
$ii = strpos($s, ']', $i);
if (! $ii) {
if ($ii === false) {
throw new InvalidEregException('"[" does not have a matching ' . '"]"');
}
$ccls = substr($s, $i + 1, $ii - ($i + 1));
@ -208,7 +208,7 @@ final class EregToPcreTransformer
++$i;
} elseif ($c === '{') {
$ii = strpos($s, '}', $i);
if (! $ii) {
if ($ii === false) {
throw new InvalidEregException('"{" does not have a matching "}"');
}
$bound = substr($s, $i + 1, $ii - ($i + 1));