@@ -349,7 +349,8 @@ class LazyVals extends MiniPhaseTransform with IdentityDenotTransformer {
349349 // compute or create appropriate offsetSymol, bitmap and bits used by current ValDef
350350 appendOffsetDefs.get(claz) match {
351351 case Some (info) =>
352- val flagsPerLong = (64 / dotty.runtime.LazyVals .BITS_PER_LAZY_VAL ).toInt
352+ val BITS_PER_LAZY_VAL = 2L // To be kept in sync with dotty.runtime.LazyVals.BITS_PER_LAZY_VAL
353+ val flagsPerLong = (64 / BITS_PER_LAZY_VAL ).toInt
353354 info.ord += 1
354355 ord = info.ord % flagsPerLong
355356 val id = info.ord / flagsPerLong
@@ -400,14 +401,15 @@ class LazyVals extends MiniPhaseTransform with IdentityDenotTransformer {
400401object LazyVals {
401402 object lazyNme {
402403 object RLazyVals {
403- import dotty .runtime .LazyVals ._
404- val get = Names .get .toTermName
405- val setFlag = Names .setFlag .toTermName
406- val wait4Notification = Names .wait4Notification .toTermName
407- val state = Names .state .toTermName
408- val cas = Names .cas .toTermName
409- val getOffset = Names .getOffset .toTermName
404+ // To be kept in sync with dotty.runtime.LazyVals.Names ._
405+ val cas = " CAS " .toTermName
406+ val get = " get " .toTermName
407+ val getOffset = " getOffset " .toTermName
408+ val setFlag = " setFlag " .toTermName
409+ val state = " STATE " .toTermName
410+ val wait4Notification = " wait4Notification " .toTermName
410411 }
412+
411413 val flag = " flag" .toTermName
412414 val result = " result" .toTermName
413415 val value = " value" .toTermName
0 commit comments