diff options
author | Martin Odersky <odersky@gmail.com> | 2014-03-10 17:48:55 +0100 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2014-03-10 17:48:55 +0100 |
commit | 7fa78597bf58a7759303095121a432cb258f447c (patch) | |
tree | 26dc6a9ed47235d50afb1d31d69693b153ae41ed /tests/new/t0039.scala | |
parent | ba8d9ea2e4b887fc0faa1f636aade84c45292144 (diff) | |
download | dotty-7fa78597bf58a7759303095121a432cb258f447c.tar.gz dotty-7fa78597bf58a7759303095121a432cb258f447c.tar.bz2 dotty-7fa78597bf58a7759303095121a432cb258f447c.zip |
Fix problems related to t0039
This test case exercised several problems:
1.)2.) Two ways to run into a cyclic references. Fixed by
- assuming an early info when completing a typedef, similarly to what is done for a classdef
- doing wellformed bounds checking in a later phase.
Failure to check whether arguments correspond to F-bounds.
- a substitution was missing.
Diffstat (limited to 'tests/new/t0039.scala')
-rw-r--r-- | tests/new/t0039.scala | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/new/t0039.scala b/tests/new/t0039.scala new file mode 100644 index 000000000..652c606b0 --- /dev/null +++ b/tests/new/t0039.scala @@ -0,0 +1,6 @@ +abstract class Extensible[A, This <: Extensible[A, This]](x: A, xs: This) { self: This => + def mkObj(x: A, xs: This): This; +} +class Fixed[A](x: A, xs: Fixed[A]) extends Extensible[A, Fixed[A]](x, xs) { + def mkObj(x: A, xs: Fixed[A]) = new Fixed(x, xs); +} |