diff options
author | Tiark Rompf <tiark.rompf@epfl.ch> | 2010-04-02 13:11:23 +0000 |
---|---|---|
committer | Tiark Rompf <tiark.rompf@epfl.ch> | 2010-04-02 13:11:23 +0000 |
commit | cd51ac694d82c68a5c02f9f20a9460adbac780b4 (patch) | |
tree | 32fafdcc00c75f53d98bd4cc84eab13a6585e255 /test/files/run/t3242b.scala | |
parent | 7b43c30aa1746cb37ee65f2871e4e92e82896a10 (diff) | |
download | scala-cd51ac694d82c68a5c02f9f20a9460adbac780b4.tar.gz scala-cd51ac694d82c68a5c02f9f20a9460adbac780b4.tar.bz2 scala-cd51ac694d82c68a5c02f9f20a9460adbac780b4.zip |
closes #3242. review by community.
Diffstat (limited to 'test/files/run/t3242b.scala')
-rw-r--r-- | test/files/run/t3242b.scala | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/test/files/run/t3242b.scala b/test/files/run/t3242b.scala new file mode 100644 index 0000000000..7a296aac15 --- /dev/null +++ b/test/files/run/t3242b.scala @@ -0,0 +1,17 @@ +import scala.collection.immutable._ + +object Test { + + def test(n: Int) = { + var vb = new VectorBuilder[Int] + for (i <- 0 until n) + vb += i + val v = vb.result + assert(v == (0 until n), "not same as (0 until " + n + "): " + v) + } + + def main(args: Array[String]): Unit = { + for (i <- 0 until 2000) + test(i) + } +} |