Going to need the iterator.

This commit is contained in:
Neil 2023-02-04 19:29:40 -08:00
parent 2fd07c2329
commit fbabdf9810
1 changed files with 3 additions and 4 deletions

View File

@ -174,9 +174,8 @@ finally:
adding a source, (probably fine.) */
const struct source *source_lookup(const struct sources *const s,
const union line64 range) {
struct source *looked;
size_t idx;
assert(s);
looked = s->list.data + source_tree_left(&s->dates, range);
/* verify ... */
return looked;
idx = source_tree_left(&s->dates, range);
return s->list.data + idx;
}