We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9d8c92d commit 9c38a61Copy full SHA for 9c38a61
src/dotty/tools/dotc/core/Types.scala
@@ -1972,14 +1972,15 @@ object Types {
1972
case class LazyRef(refFn: () => Type) extends UncachedProxyType with ValueType {
1973
private var myRef: Type = null
1974
private var computed = false
1975
- lazy val ref = {
+ def ref = {
1976
if (computed) assert(myRef != null)
1977
else {
1978
computed = true
1979
myRef = refFn()
1980
}
1981
myRef
1982
1983
+ def evaluating = computed && myRef == null
1984
override def underlying(implicit ctx: Context) = ref
1985
override def toString = s"LazyRef($ref)"
1986
override def equals(other: Any) = other match {
0 commit comments