diff --git a/lynglib/stdlib/lyng/root.lyng b/lynglib/stdlib/lyng/root.lyng index 0fd0f03..814f63f 100644 --- a/lynglib/stdlib/lyng/root.lyng +++ b/lynglib/stdlib/lyng/root.lyng @@ -8,6 +8,18 @@ extern class IllegalArgumentException extern class NotImplementedException extern class Delegate +extern class Iterable { + fun iterator(): Iterator + fun toList(): List +} + +extern class Iterator { + fun hasNext(): Bool + fun next(): T + fun cancelIteration(): Void + fun toList(): List +} + // Built-in math helpers (implemented in host runtime). extern fun abs(x: Object): Real extern fun ln(x: Object): Real