Hi,

In message "Re: Range#length?!?!?"
    on 03/02/12, ahoward <ahoward / fsl.noaa.gov> writes:

|> Interesting.
|
|is that good, or bad?  ;-)

Neutral.

|i guess the question is WHAT a Range of strings is :
|
|  * all possible comibnations between start and end
|  * a linear (succ) progression between start and end

Range serves purpose of both

  (a) sequence of values from beg to end (need "succ" to work)
  (b) interval from beg to end

When values are Strings, Range works as (a), whereas for Floats, it
works as (b), and both for Fixnum.

The reason I removed "length" and "size" from Range is that you cannot
tell which role a range takes.

|>   for x in 0.0 ... 42.0
|>     ...
|>   end
|>
|> stops.
|
|confused ??
|
|irb(main):001:0> for x in 0.0 ... 42.0; end
|TypeError: cannot iterate from Float
|from (irb):1:in `each'
|from (irb):1

Sorry, it used to be possible.  I forget the change I did.

							matz.