blob: 4c1973cad61ff4e4dd0dca77f88f6231f652cb55 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
object sigs {
type Lst[A] = List[A]
type Twin[B] = (B, B)
var x = 7 * 9
class Base {
def foo(x: Int): Any = 33
def foo: Object = "x"
}
class Sub extends Base {
override def foo = "abc"
override def foo(x: Int) = "abc"
}
trait A { self: B =>
type AA
val a: AA & BB
}
trait B { this: A =>
type BB
val b: AA & BB
}
class C extends A with B {
type AA = String
type BB = AnyRef
val a = ""
val b = ""
}
}
|