···2121 "hash/crc64"
2222 "log"
2323 "math/bits"
2424+ "slices"
2425 "unicode/utf8"
25262627 "github.com/sourcegraph/zoekt/query"
2727- "golang.org/x/exp/slices"
2828)
29293030// indexData holds the pattern-independent data that we have to have
···410410411411 // PERF: Sort to increase the chances adjacent checks are in the same btree
412412 // bucket (which can cause disk IO).
413413- slices.SortFunc(ngramOffs, func(a, b runeNgramOff) bool {
414414- return a.ngram < b.ngram
415415- })
413413+ slices.SortFunc(ngramOffs, runeNgramOff.Compare)
416414 frequencies := make([]uint32, 0, len(ngramOffs))
417415 ngramLookups := 0
418416 ngrams := d.ngrams(query.FileName)