Skip to content

Commit e71cff4

Browse files
Seldaekondrejmirtes
authored andcommitted
Apply Grammar.patch to reflect previous phpstan state
1 parent bacb3c6 commit e71cff4

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

resources/RegexGrammar.pp

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
%token co:comment .*?(?=(?<!\\)\))
7474

7575
// Capturing group.
76-
%token named_capturing_ \(\?< -> nc
76+
%token named_capturing_ \(\?P?< -> nc
7777
%token nc:_named_capturing > -> default
7878
%token nc:capturing_name .+?(?=(?<!\\)>)
7979
%token non_capturing_ \(\?:
@@ -109,7 +109,7 @@
109109
// Please, see PCRESYNTAX(3), General Category properties, PCRE special category
110110
// properties and script names for \p{} and \P{}.
111111
%token character_type \\([CdDhHNRsSvVwWX]|[pP]{[^}]+})
112-
%token anchor \\(bBAZzG)|\^|\$
112+
%token anchor \\([bBAZzG])|\^|\$
113113
%token match_point_reset \\K
114114
%token literal \\.|.
115115

@@ -168,7 +168,7 @@
168168
::negative_class_:: #negativeclass
169169
| ::class_::
170170
)
171-
( range() | literal() )+
171+
( <class_> | range() | literal() )+
172172
::_class::
173173

174174
#range:
@@ -178,7 +178,7 @@
178178
capturing()
179179
| literal()
180180

181-
capturing:
181+
#capturing:
182182
::comment_:: <comment>? ::_comment:: #comment
183183
| (
184184
::named_capturing_:: <capturing_name> ::_named_capturing:: #namedcapturing
@@ -191,6 +191,7 @@
191191

192192
literal:
193193
<character>
194+
| <range>
194195
| <dynamic_character>
195196
| <character_type>
196197
| <anchor>

0 commit comments

Comments
 (0)