We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
??=
1 parent 3c4bcf2 commit 6d8d1e3Copy full SHA for 6d8d1e3
src/Type/Regex/RegexGroupParser.php
@@ -53,10 +53,8 @@ public function __construct(
53
54
public function parseGroups(string $regex): ?RegexAstWalkResult
55
{
56
- if (self::$parser === null) {
57
- /** @throws void */
58
- self::$parser = Llk::load(new Read(__DIR__ . '/../../../resources/RegexGrammar.pp'));
59
- }
+ /** @throws void */
+ self::$parser ??= Llk::load(new Read(__DIR__ . '/../../../resources/RegexGrammar.pp'));
60
61
try {
62
Strings::match('', $regex);
0 commit comments