Skip to content

insert_overlap does not sometimes merge intervals #49

@lailoken

Description

@lailoken

So it seems that insert_overlap merges the inserted item to a interval in the tree if there is overlap, but it does not merge to all overlapped intervals.

Not sure if this is by design:

  insert_overlap [0-9]
  insert_overlap [20-29]
  -> [0-9] [20-29]

  insert_overlap [10-19]
  -> [0-19] [20-29] // should have been merged.

  Deoverlap
  -> [0-29] // this is what I expected above

Same if that last insert_overlap was clearly larger (obviously, but I tested anyway):

  insert_overlap [9-20]
  -> [0-20] [20-29] // should have been merged.

For now I always do a deoverlap() after insert_overlap (I only use insert_overlap in my app), which seems redundant.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions