Skip to content

Commit

Permalink
fix(matcher): match end_pos when finding relative to another match
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed Jun 16, 2023
1 parent dadca0e commit 0794ba2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/flash/matcher.lua
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ function M:find(opts)

if opts.match then
for m, match in ipairs(self.matches) do
if match == opts.match then
if match.pos == opts.match.pos and match.end_pos == opts.match.end_pos then
idx = m + (opts.forward and 1 or -1)
break
end
Expand Down

0 comments on commit 0794ba2

Please sign in to comment.