aboutsummaryrefslogtreecommitdiff
path: root/tests/run/t4697.scala
diff options
context:
space:
mode:
Diffstat (limited to 'tests/run/t4697.scala')
-rw-r--r--tests/run/t4697.scala8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/run/t4697.scala b/tests/run/t4697.scala
new file mode 100644
index 000000000..95592172e
--- /dev/null
+++ b/tests/run/t4697.scala
@@ -0,0 +1,8 @@
+object Test {
+ var st = Stream(0)
+ for (i <- 1 to 10000) st = i +: st
+
+ def main(args: Array[String]): Unit = {
+ println(st.take(10000).sum)
+ }
+}