fill_gaps now handles revers appropriately for before/after/external and returns if end <= start