fix: find the closest matching symbol not the largest enclosing symbol
This commit is contained in:
parent
8c0eac80cf
commit
db8bd0840f
1 changed files with 0 additions and 2 deletions
|
|
@ -196,8 +196,6 @@ fn find_closest(palette: *Type) ?usize {
|
|||
var previous: usize = 0;
|
||||
for (palette.entries.items, 0..) |entry, idx| {
|
||||
_, _, _, const sel = get_values(entry.cbor);
|
||||
if (cursor.within(sel))
|
||||
return idx + 1;
|
||||
if (cursor.row < sel.begin.row) return previous + 1;
|
||||
previous = idx;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue