Sha256: 0dce05d8cec70a92eb3c8d1309f4fe9a178c2e4511980affb16a69b5acf08cbf

Contents?: true

Size: 467 Bytes

Versions: 4

Compression:

Stored size: 467 Bytes

Contents

class Range {
  """
  Class of Range values. Are created by using Range literal syntax in Fancy.

  Example:
        (10..100) # Range from 10 to 100
        # the following code does the same as above:
        Range new: 10 to: 100
  """

  include: Fancy Enumerable

  def to_s {
    """
    Same as Range#inspect
    """

    inspect
  }

  def inspect {
    """
    @return @String@ representation of @self.
    """

    "(" ++ @start ++ ".." ++ @end ++ ")"
  }
}

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
fancy-0.9.0 lib/range.fy
fancy-0.8.0 lib/range.fy
fancy-0.7.0 lib/range.fy
fancy-0.6.0 lib/range.fy