diff options
author | Martin Odersky <odersky@gmail.com> | 2016-08-24 12:37:50 +0200 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2016-08-26 11:13:17 +0200 |
commit | eb529b556f92a5ab0329899762b43eea7103ad59 (patch) | |
tree | eacf21670fe6bc75fa4f9c3696da8f2d64965982 /tests | |
parent | f8970818e3d285b7827a035bffb26c1a4b97319e (diff) | |
download | dotty-eb529b556f92a5ab0329899762b43eea7103ad59.tar.gz dotty-eb529b556f92a5ab0329899762b43eea7103ad59.tar.bz2 dotty-eb529b556f92a5ab0329899762b43eea7103ad59.zip |
Generalize self-referential member comparisons.
The special case in hasMatchingMember dealing with self-refential
members has to be generalized to deal lower and upper bounds.
Test case is t762.scala
Diffstat (limited to 'tests')
-rw-r--r-- | tests/pending/pos/t762.scala | 2 | ||||
-rw-r--r-- | tests/pos/t762.scala | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/tests/pending/pos/t762.scala b/tests/pending/pos/t762.scala deleted file mode 100644 index 76860272e..000000000 --- a/tests/pending/pos/t762.scala +++ /dev/null @@ -1,2 +0,0 @@ -trait Foo { type T } -trait Bar extends Foo { val x : Foo { type T <: Bar.this.T } = this : this.type } diff --git a/tests/pos/t762.scala b/tests/pos/t762.scala new file mode 100644 index 000000000..c5bf39b0c --- /dev/null +++ b/tests/pos/t762.scala @@ -0,0 +1,4 @@ +trait Foo { type T } +trait Bar1 extends Foo { val x : Foo { type T <: Bar1.this.T } = this } +trait Bar2 extends Foo { val x : Foo { type T = Bar2.this.T } = this } +trait Bar3 extends Foo { val x : Foo { type T >: Bar3.this.T } = this } |