@@ -354,7 +354,7 @@ trait BCodeHelpers extends BCodeIdiomatic with BytecodeWriters {
354
354
av.visit(name, const.stringValue) // `stringValue` special-cases null, but that execution path isn't exercised for a const with StringTag
355
355
case ClazzTag => av.visit(name, typeToTypeKind(const.typeValue)(bcodeStore)(innerClasesStore).toASMType)
356
356
case EnumTag =>
357
- val edesc = innerClasesStore.typeDescriptor(const.tpe) // the class descriptor of the enumeration class.
357
+ val edesc = innerClasesStore.typeDescriptor(const.tpe. asInstanceOf [bcodeStore.int. Type ] ) // the class descriptor of the enumeration class.
358
358
val evalue = const.symbolValue.name.mangledString // value the actual enumeration value.
359
359
av.visitEnum(name, edesc, evalue)
360
360
}
@@ -363,7 +363,7 @@ trait BCodeHelpers extends BCodeIdiomatic with BytecodeWriters {
363
363
case Ident (nme.WILDCARD ) =>
364
364
// An underscore argument indicates that we want to use the default value for this parameter, so do not emit anything
365
365
case t : tpd.RefTree if t.symbol.denot.owner.isAllOf(Flags .JavaEnumTrait ) =>
366
- val edesc = innerClasesStore.typeDescriptor(t.tpe) // the class descriptor of the enumeration class.
366
+ val edesc = innerClasesStore.typeDescriptor(t.tpe. asInstanceOf [bcodeStore.int. Type ] ) // the class descriptor of the enumeration class.
367
367
val evalue = t.symbol.name.mangledString // value the actual enumeration value.
368
368
av.visitEnum(name, edesc, evalue)
369
369
case t : SeqLiteral =>
@@ -405,7 +405,7 @@ trait BCodeHelpers extends BCodeIdiomatic with BytecodeWriters {
405
405
case t @ Apply (constr, args) if t.tpe.derivesFrom(JavaAnnotationClass ) =>
406
406
val typ = t.tpe.classSymbol.denot.info
407
407
val assocs = assocsFromApply(t)
408
- val desc = innerClasesStore.typeDescriptor(typ) // the class descriptor of the nested annotation class
408
+ val desc = innerClasesStore.typeDescriptor(typ. asInstanceOf [bcodeStore.int. Type ] ) // the class descriptor of the nested annotation class
409
409
val nestedVisitor = av.visitAnnotation(name, desc)
410
410
emitAssocs(nestedVisitor, assocs, bcodeStore)(innerClasesStore)
411
411
@@ -756,8 +756,8 @@ trait BCodeHelpers extends BCodeIdiomatic with BytecodeWriters {
756
756
def primitiveOrClassToBType (sym : Symbol ): BType = {
757
757
assert(sym.isClass, sym)
758
758
assert(sym != defn.ArrayClass || ctx.compilationUnit.source.file.name == " Array.scala" , sym)
759
- primitiveTypeMap.getOrElse(sym,
760
- storage.getClassBTypeAndRegisterInnerClass(sym)).asInstanceOf [BType ]
759
+ primitiveTypeMap.getOrElse(sym. asInstanceOf [ct.bTypes.coreBTypes.bTypes.int. Symbol ] ,
760
+ storage.getClassBTypeAndRegisterInnerClass(sym. asInstanceOf [ct.int. Symbol ] )).asInstanceOf [BType ]
761
761
}
762
762
763
763
/**
@@ -809,7 +809,7 @@ trait BCodeHelpers extends BCodeIdiomatic with BytecodeWriters {
809
809
810
810
tp match {
811
811
case tp : ThisType if tp.cls == defn.ArrayClass => ObjectReference .asInstanceOf [ct.bTypes.ClassBType ] // was introduced in 9b17332f11 to fix SI-999, but this code is not reached in its test, or any other test
812
- case tp : ThisType => storage.getClassBTypeAndRegisterInnerClass(tp.cls)
812
+ case tp : ThisType => storage.getClassBTypeAndRegisterInnerClass(tp.cls. asInstanceOf [ct.int. Symbol ] )
813
813
// case t: SingletonType => primitiveOrClassToBType(t.classSymbol)
814
814
case t : SingletonType => typeToTypeKind(t.underlying)(ct)(storage)
815
815
case t : RefinedType => typeToTypeKind(t.parent)(ct)(storage) // parents.map(_.toTypeKind(ct)(storage).asClassBType).reduceLeft((a, b) => a.jvmWiseLUB(b))
0 commit comments