aboutsummaryrefslogtreecommitdiff
path: root/tests/pos
diff options
context:
space:
mode:
authorodersky <odersky@gmail.com>2015-11-17 22:02:10 +0100
committerodersky <odersky@gmail.com>2015-11-17 22:02:10 +0100
commitda97bfb6e1284f906d529b62ca4c1c69e15c140e (patch)
treeec57941728389450297195da83377033db0691a7 /tests/pos
parent57d05d3cc2456bcb7bfa743ad664690ad5a3aaac (diff)
parent3ec504cf4586dc99964b1b049eae745077c20b37 (diff)
downloaddotty-da97bfb6e1284f906d529b62ca4c1c69e15c140e.tar.gz
dotty-da97bfb6e1284f906d529b62ca4c1c69e15c140e.tar.bz2
dotty-da97bfb6e1284f906d529b62ca4c1c69e15c140e.zip
Merge pull request #957 from dotty-staging/fix-#938
Fix #938
Diffstat (limited to 'tests/pos')
-rw-r--r--tests/pos/i938.scala21
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/pos/i938.scala b/tests/pos/i938.scala
new file mode 100644
index 000000000..cf8fd76e3
--- /dev/null
+++ b/tests/pos/i938.scala
@@ -0,0 +1,21 @@
+object Test {
+ import scala.collection._
+
+ trait T {
+ def f() : Unit
+ }
+
+ def view = new T {
+ def f() = ()
+ }
+
+ trait TLike[+A, RR] { self =>
+
+ def repr: RR = ???
+
+ def view2 = new TraversableView[A, RR] {
+ protected lazy val underlying = self.repr
+ override def foreach[U](f: A => U): Unit = ???
+ }
+ }
+}