diff options
author | Martin Odersky <odersky@gmail.com> | 2015-10-04 10:33:54 +0200 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2015-10-06 13:54:36 +0200 |
commit | 135b7255b3e90117cca9d046a89ef779adbef783 (patch) | |
tree | 7b678a9a30aa9ef682fb4c301e0f3cad7991115a /tests/run | |
parent | 868ae2acb4ef66fa6c32b45e10ba9940ba7340ad (diff) | |
download | dotty-135b7255b3e90117cca9d046a89ef779adbef783.tar.gz dotty-135b7255b3e90117cca9d046a89ef779adbef783.tar.bz2 dotty-135b7255b3e90117cca9d046a89ef779adbef783.zip |
Add ArrayBuffer as another Seq class. Make iterators inspectable.
Diffstat (limited to 'tests/run')
-rw-r--r-- | tests/run/CollectionTests.check | 17 | ||||
-rw-r--r-- | tests/run/CollectionTests.scala | 2 |
2 files changed, 19 insertions, 0 deletions
diff --git a/tests/run/CollectionTests.check b/tests/run/CollectionTests.check index 3afe62813..7c4f6e77a 100644 --- a/tests/run/CollectionTests.check +++ b/tests/run/CollectionTests.check @@ -21,6 +21,23 @@ Cons(3,Cons(2,Cons(1,Nil))) 1 1 Cons(1,Cons(2,Cons(3,Nil))) +Array(2) +Array(1, 3) +Array(3) +Array(true, true, true) +Array(1, -1, 2, -2, 3, -3) +Array(1, 2, 3, 1, 2, 3) +Array(1, 2, 3) +Cons(1,Cons(2,Cons(3,Nil))) +Array(1, 2, 3, a) +Array((1,true), (2,true), (3,true)) +Array(3, 2, 1) +------- +123 +123 +1 +1 +Cons(1,Cons(2,Cons(3,Nil))) Cons(2,Nil) Cons(1,Cons(3,Nil)) Cons(3,Nil) diff --git a/tests/run/CollectionTests.scala b/tests/run/CollectionTests.scala index 46cb63544..0421cfbe4 100644 --- a/tests/run/CollectionTests.scala +++ b/tests/run/CollectionTests.scala @@ -160,8 +160,10 @@ object Test { def main(args: Array[String]) = { val ints = Cons(1, Cons(2, Cons(3, Nil))) + val intsBuf = ints.collect(ArrayBuffer) val intsView = ints.view seqOps(ints) + seqOps(intsBuf) viewOps(intsView) stringOps("abc") } |