blob: 9de9aa0d5a4d1e042c2b070143f3bcea08bb4da1 (
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
43
44
45
46
47
48
49
|
package dotty.tools.dotc
package core
import Decorators._
import Periods._
import Names._
import Phases._
import Types._
object Contexts {
val NoContext: Context = null
abstract class Context extends Periods {
val underlying: Context
val root: RootContext
val period: Period
def names: NameTable
def phase: Phase = ???
def stableInterval: Interval = ???
def erasedTypes: Boolean = ???
}
abstract class SubContext(val underlying: Context) extends Context {
val root: RootContext = underlying.root
val period: Period = underlying.period
def names: NameTable = root.names
}
class RootContext extends Context
with Symbols
with Denotations
with DenotationTransformers
with Types {
val underlying: Context = throw new UnsupportedOperationException("RootContext.underlying")
val root: RootContext = this
val period = periodOf(NoRunId, NoPhaseId)
val names: NameTable = new NameTable
val variance = 1
var lastPhaseId: Int = NoPhaseId
lazy val definitions = new Definitions()(this)
}
private final val initialUniquesCapacity = 4096
}
|