Skip to content

Commit 71d689c

Browse files
committed
Avoided relying on class symbols of primitive value types during unpickling. They might not be initialized yet (as seen during bootstrapped tests).
1 parent 94d73ce commit 71d689c

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

compiler/src/dotty/tools/dotc/core/unpickleScala2/Scala2Unpickler.scala

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -426,8 +426,7 @@ class Scala2Unpickler(bytes: Array[Byte], classRoot: ClassDenotation, moduleClas
426426
// TODO(gsps): This is a hack to mark certain primitive methods as stable.
427427
// In the future such primitive methods should be pickled with the Stable flag set.
428428
def markPrimitiveStable(owner: Symbol, name: Name, flags: FlagSet): FlagSet =
429-
if (defn.ScalaValueClasses().contains(owner)) flags | Stable
430-
else flags
429+
if (tpnme.ScalaValueNames.contains(defn.scalaClassName(owner))) flags | Stable else flags
431430

432431
tag match {
433432
case NONEsym => return NoSymbol

0 commit comments

Comments
 (0)