search: disable parentheses heuristic for recognized operators
Created by: rvantonder
We want a pattern like (() main func())
to be treated literally according to the heuristic that recognizes this input. This same heuristic will interpret (() or main())
literally, but in this case, the subexpression is a valid or-expression that we should parse rather than apply this heuristic.
This PR fixes the above, but really it is a stopgap because as I'm introducing more complex testing cases, I'm realizing that this heuristic doesn't really cut it for the behaviors we care about, and I will rework this logic soon.
Merge request reports
Activity
Created by: codecov[bot]
Codecov Report
Merging #11128 into master will not change coverage. The diff coverage is
100.00%
.@@ Coverage Diff @@ ## master #11128 +/- ## ======================================= Coverage 46.39% 46.39% ======================================= Files 1367 1367 Lines 77136 77136 Branches 6553 6606 +53 ======================================= Hits 35786 35786 Misses 37951 37951 Partials 3399 3399
Flag Coverage Δ #go 50.47% <100.00%> (ø)
#storybook 6.88% <ø> (ø)
#typescript 35.84% <ø> (ø)
#unit 46.18% <100.00%> (ø)
Impacted Files Coverage Δ internal/search/query/parser.go 91.94% <100.00%> (ø)
Please register or sign in to reply