def from_to(first, last, options=nil)
      if options && options.is_a?(Hash)
        maxcount = options.has_key?(:max) ? options[:max] : false
        lastincluded = options.has_key?(:last_included?) ? options[:last_included?] : true
      else
        maxcount = false
        lastincluded = true
      end
      ret = [first]
      count = 1
      while true
        first = yield(first)
        if first == last or (maxcount ? (count > maxcount) : false)
          ret << first if lastincluded
          break
        end
        ret << first
      end
      ret
    end
def from_to(first, last, options=nil)
      if options && options.is_a?(Hash)
        maxcount = options.has_key?(:max) ? options[:max] : false
        lastincluded = options.has_key?(:last_included?) ? options[:last_included?] : true
      else
        maxcount = false
        lastincluded = true
      end
      ret = [first]
      count = 1
      while true
        first = yield(first)
        if first == last or (maxcount ? (count > maxcount) : false)
          ret << first if lastincluded
          break
        end
        ret << first
      end
      ret
    end
FIXME I don't know really why I designed this ... possibly drop candidate
 returns an array containing from +first+ to +last+
 options is a hash that can contain:
 +:comp=>eq_method+ is a a symbol with the name of the method that sent to
     an element with another element as parameter evaluates equality. If not
     supplied +:==+ assumed.
 +:max=>max_num+ is the maximum size of the returned array. If not supplied
     false assumed (no limit)
 +:last_included?=>true or false+ tells if +last+ should be included.
     If not included +true+ assumed
 The code block is not optional: it is passed an element and should return
 the next.