File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
compiler/src/dotty/tools/dotc/core Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -4396,13 +4396,13 @@ object Types {
43964396 private var myInst : Type = NoType
43974397
43984398 private [core] def inst : Type = myInst
4399- private [core] def inst_= (tp : Type ): Unit = {
4399+ private [core] def inst_= (tp : Type ): Unit =
44004400 myInst = tp
4401- if ( tp.exists && ( owningState ne null )) {
4402- owningState.get.ownedVars -= this
4403- owningState = null // no longer needed; null out to avoid a memory leak
4404- }
4405- }
4401+ if tp.exists && owningState != null then
4402+ val owningState1 = owningState.get
4403+ if owningState1 ! = null then
4404+ owningState1.ownedVars -= this
4405+ owningState = null // no longer needed; null out to avoid a memory leak
44064406
44074407 /** The state owning the variable. This is at first `creatorState`, but it can
44084408 * be changed to an enclosing state on a commit.
You can’t perform that action at this time.
0 commit comments