aboutsummaryrefslogtreecommitdiff
path: root/tests/pos/i938.scala
diff options
context:
space:
mode:
Diffstat (limited to 'tests/pos/i938.scala')
-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 = ???
+ }
+ }
+}