Skip to content

Commit

Permalink
Fix bug: Replace * with *? in QuantifierToken regex pattern
Browse files Browse the repository at this point in the history
  • Loading branch information
christopher-hampson committed Oct 29, 2023
1 parent 44503d7 commit 4de4b6d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion automata/regex/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,7 @@ def get_regex_lexer(
lexer.register_token(KleeneStarToken.from_match, r"\*")
lexer.register_token(KleenePlusToken.from_match, r"\+")
lexer.register_token(OptionToken.from_match, r"\?")
lexer.register_token(QuantifierToken.from_match, r"\{(.*),(.*)\}")
lexer.register_token(QuantifierToken.from_match, r"\{(.*?),(.*?)\}")
lexer.register_token(
lambda match: WildcardToken(match.group(), input_symbols, state_name_counter),
r"\.",
Expand Down

0 comments on commit 4de4b6d

Please sign in to comment.