mirror of
https://github.com/Llewellynvdm/fzf.git
synced 2024-11-11 08:10:54 +00:00
Update FuzzyMatchV1 to use skip optimization used in V2
This commit is contained in:
parent
6c76d8cd1c
commit
6bc592e6c9
@ -586,6 +586,9 @@ func FuzzyMatchV1(caseSensitive bool, normalize bool, forward bool, text util.Ch
|
|||||||
if len(pattern) == 0 {
|
if len(pattern) == 0 {
|
||||||
return Result{0, 0, 0}, nil
|
return Result{0, 0, 0}, nil
|
||||||
}
|
}
|
||||||
|
if asciiFuzzyIndex(&text, pattern, caseSensitive) < 0 {
|
||||||
|
return Result{-1, -1, 0}, nil
|
||||||
|
}
|
||||||
|
|
||||||
pidx := 0
|
pidx := 0
|
||||||
sidx := -1
|
sidx := -1
|
||||||
|
Loading…
Reference in New Issue
Block a user