Skip to content
FutureBlitz

    Install

    Import std.core.range

    std.core.range

    Range<T>: the integers a range gives, like 0 Until 10, 1 To 10, or 10 To 0 Step -2, which are the values a For loop with those bounds counts. The compiler makes each one from what's written, so a Range holds only the value it gives next, its step, and how many steps come after that value. An empty range is a Range's zero. Ranges are == when they give the same values.

    std/core/range.fb

    Types

    Range struct

    Public Struct Range<T: Numeric> Implements Iterator<T>, Iterable<T>

    The integers from a start to an end, by a step, as a range like 0 Until 10 gives them.

    std/core/range.fb, line 10

    • Public ByRef Method Next(): T? method #

      The next value, or Null after the last one.

    • Public Method Iterate(): Range<T> method #

      A copy of the range, which goes over its values from where it is.

    Extends

    Range extend

    Extend Range<T>

    No doc comment.

    std/core/range.fb, line 40

    • Operator ==(a: Range<T>, b: Range<T>): Bool operator #

      Whether a and b give the same values: every range that gives none does, whatever it gave before, and the step counts only where there's a value after Current.

    Report an issue with this page or with FutureBlitz on GitHub.