Skip to content

Commit 911d071

Browse files
azizkprincemaple
authored andcommitted
RegExp: fix: match optional lazy_or_possessive after ranged quantifier.
1 parent 6b638bf commit 911d071

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

Regular Expressions (Elixir).sublime-syntax

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -438,7 +438,7 @@ contexts:
438438
scope: invalid.illegal.unknown-posix-class.regexp.elixir
439439

440440
quantifier:
441-
- match: ({)(\d+)(,)?(\d*)(})
441+
- match: ({)(\d+)(,)?(\d*)(}){{lazy_or_possessive}}?
442442
scope: meta.quantifier.regexp.elixir keyword.operator.quantifier.regexp.elixir
443443
captures:
444444
1: punctuation.definition.quantifier.begin.regexp.elixir
@@ -448,12 +448,10 @@ contexts:
448448
5: punctuation.definition.quantifier.end.regexp.elixir
449449
push: unexpected_quantifier_pop
450450
- match: '{{character_quantifier}}{{lazy_or_possessive}}?'
451-
scope: keyword.operator.quantifier.regexp.elixir
451+
scope: meta.quantifier.regexp.elixir keyword.operator.quantifier.regexp.elixir
452452
push: unexpected_quantifier_pop
453453

454454
unexpected_quantifier:
455-
- match: '{{ranged_quantifier}}'
456-
scope: invalid.illegal.unexpected-quantifier.regexp.elixir
457455
- match: (?>{{character_quantifier}}|{{ranged_quantifier}})+
458456
scope: invalid.illegal.unexpected-quantifier.regexp.elixir
459457

0 commit comments

Comments
 (0)