mirror of
https://github.com/github/semantic.git
synced 2024-12-22 22:31:36 +03:00
Take the index of the first, not last, element.
This commit is contained in:
parent
f30029d16d
commit
2ca40cad2b
@ -248,7 +248,7 @@ mapContiguous canCompare = go 0 0 id id
|
||||
These a b -> mapChunk (ls []) (rs []) <> (These (i, a) (j, b) : go (succ i) (succ j) id id rest)
|
||||
mapChunk ls [] = This . (termIndex &&& term) <$> ls
|
||||
mapChunk [] rs = That . (termIndex &&& term) <$> rs
|
||||
mapChunk ls rs = findNearestNeighbourTo' canCompare (toKdMap ls) (toKdMap rs) (termIndex (last ls)) ls rs
|
||||
mapChunk ls rs = findNearestNeighbourTo' canCompare (toKdMap ls) (toKdMap rs) (termIndex (head ls)) ls rs
|
||||
|
||||
|
||||
genFeaturizedTermsAndDiffs :: Functor syntax
|
||||
|
Loading…
Reference in New Issue
Block a user