blob: d5e9f6df343f1b4bb11780d6272dc191ea06d287 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
trait Linked {
type File <: FileImpl;
trait FileImpl {
Console.println("Hello from linked");
}
}
object Test {
class Test extends Linked {
trait FileImpl extends super.FileImpl {
// val x: int = 1
}
class File extends FileImpl;
}
def main(args : Array[String]) : Unit = {
Console.println("BEGIN");
val test = new Test;
val file = new test.File;
Console.println("END");
}
}
|