Skip to content

Commit

Permalink
Update condition_parser.go
Browse files Browse the repository at this point in the history
  • Loading branch information
AdrielVelazquez authored Feb 28, 2024
1 parent 55d2081 commit 40048aa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions condition_parser.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ import (
var (
searchExprLexer = lexer.Must(lexer.Regexp(`(?P<Keyword>(?i)(1 of them)|(all of them)|(1 of)|(all of))` +
`|(?P<SearchIdentifierPattern>\*?[a-zA-Z_]+(?:[a-zA-Z0-9_]*_)*[a-zA-Z0-9]*\*)` + // Adjusted pattern to catch multiple underscores which is present upstream
`|(?P<SearchIdentifier>[a-zA-Z_][a-zA-Z0-9_]*)` + // TODO: this never actually matches anything because they get matched as a SearchIdentifier instead. However this isn't currently a problem because we don't parse anything in the Grammar as an Operator (we just use string constants which don't care about Operator vs SearchIdentifier)
`|(?P<Operator>(?i)and|or|not|[()])` +
`|(?P<SearchIdentifier>[a-zA-Z_][a-zA-Z0-9_]*)` +
`|(?P<Operator>(?i)and|or|not|[()])` + // TODO: this never actually matches anything because they get matched as a SearchIdentifier instead. However this isn't currently a problem because we don't parse anything in the Grammar as an Operator (we just use string constants which don't care about Operator vs SearchIdentifier)
`|(?P<ComparisonOperation>=|!=|<=|>=|<|>)` +
`|(?P<ComparisonValue>0|[1-9][0-9]*)` +
`|(?P<Pipe>[|])` +
Expand Down

0 comments on commit 40048aa

Please sign in to comment.