summaryrefslogtreecommitdiff
path: root/test/pending/run/t2897.scala
diff options
context:
space:
mode:
Diffstat (limited to 'test/pending/run/t2897.scala')
-rw-r--r--test/pending/run/t2897.scala22
1 files changed, 22 insertions, 0 deletions
diff --git a/test/pending/run/t2897.scala b/test/pending/run/t2897.scala
new file mode 100644
index 0000000000..40fd3c2b08
--- /dev/null
+++ b/test/pending/run/t2897.scala
@@ -0,0 +1,22 @@
+class A {
+ def f1(t: String) = {
+ trait T {
+ def xs = Nil map (_ => t)
+ }
+ }
+ def f2(t: String) = {
+ def xs = Nil map (_ => t)
+ }
+ def f3(t: String) = {
+ var t1 = 5
+ trait T {
+ def xs = { t1 = 10 ; t }
+ }
+ }
+ def f4() = {
+ var u = 5
+ trait T {
+ def xs = Nil map (_ => u = 10)
+ }
+ }
+}