File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
compiler/src/dotty/tools/dotc/core Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -12,9 +12,19 @@ import printing.Texts._
12
12
import config .Config
13
13
import collection .mutable
14
14
import java .lang .ref .WeakReference
15
+ import Decorators ._
16
+
17
+ object TyperState {
18
+ @ sharable private var nextId : Int = 0
19
+ }
15
20
16
21
class TyperState (previous : TyperState /* | Null */ ) extends DotClass with Showable {
17
22
23
+ val id = TyperState .nextId
24
+ TyperState .nextId += 1
25
+
26
+ // assert(id != 146)
27
+
18
28
private [this ] var myReporter =
19
29
if (previous == null ) new ConsoleReporter () else previous.reporter
20
30
@@ -171,7 +181,7 @@ class TyperState(previous: TyperState /* | Null */) extends DotClass with Showab
171
181
constraint = constraint.remove(poly)
172
182
}
173
183
174
- override def toText (printer : Printer ): Text = constraint.toText(printer)
184
+ override def toText (printer : Printer ): Text = s " TS[ $id ] "
175
185
176
186
def hashesStr : String =
177
187
if (previous == null ) " " else hashCode.toString + " -> " + previous.hashesStr
You can’t perform that action at this time.
0 commit comments