```ruby def until(terminus) return enum_for(:until, terminus) unless block_given? periods .map { |period| period & comparison_period(period, terminus) } .each do |period| break if occurred?(period, terminus) yield period unless period.disjoint? end end ```