diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/files/run/indexedSeq.scala | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/files/run/indexedSeq.scala b/test/files/run/indexedSeq.scala new file mode 100644 index 0000000000..19308e1d8c --- /dev/null +++ b/test/files/run/indexedSeq.scala @@ -0,0 +1,10 @@ +object Test { + import scala.collection.{ mutable, immutable, generic } + + def checkIdentity[A](xs: immutable.IndexedSeq[A]) = assert(xs.toIndexedSeq eq xs) + + def main(args: Array[String]): Unit = { + checkIdentity(immutable.Vector(1 to 10: _*)) + checkIdentity(1 to 10 toIndexedSeq) + } +} |