summaryrefslogtreecommitdiff
path: root/test/files/run/iterables.scala
diff options
context:
space:
mode:
Diffstat (limited to 'test/files/run/iterables.scala')
-rw-r--r--test/files/run/iterables.scala18
1 files changed, 15 insertions, 3 deletions
diff --git a/test/files/run/iterables.scala b/test/files/run/iterables.scala
index 7a29b80e8d..5fb587a323 100644
--- a/test/files/run/iterables.scala
+++ b/test/files/run/iterables.scala
@@ -8,7 +8,19 @@ object Test extends Application {
else throw new IndexOutOfBoundsException("empty iterator")
}
}
- val x = new Test(10)
- println(x.isEmpty)
- println(x.mkString(","))
+ {
+ val x = new Test(10)
+ println(x.isEmpty)
+ println(x.mkString(","))
+ }
+ {
+ val x = new Test(10)
+ println(x.filter(_ > 4).mkString(","))
+ }
+ {
+ val x = new Test(10)
+ val y = x.partition(_ % 2 == 0)
+ println(y._1.mkString(","))
+ println(y._2.mkString(","))
+ }
}