diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/compiler/scala/tools/nsc/transform/SpecializeTypes.scala | 2 | ||||
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Typers.scala | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/transform/SpecializeTypes.scala b/src/compiler/scala/tools/nsc/transform/SpecializeTypes.scala index 28a9818017..7b0f5254b6 100644 --- a/src/compiler/scala/tools/nsc/transform/SpecializeTypes.scala +++ b/src/compiler/scala/tools/nsc/transform/SpecializeTypes.scala @@ -348,7 +348,7 @@ abstract class SpecializeTypes extends InfoTransform with TypingTransformers { */ def specializesClass(sym: Symbol): Symbol = { val c = sym.companionClass - if (isValueClass(c)) c else AnyRefClass + if (isPrimitiveValueClass(c)) c else AnyRefClass } /** Return the types `sym` should be specialized at. This may be some of the primitive types diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index 65c46fca98..9a2ef88821 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -637,7 +637,7 @@ trait Typers extends Modes with Adaptations with PatMatVirtualiser { // to escape scope here, e.g. pos/t1107. I'm not sure how to properly handle this // so for now it requires the type symbol be public. && pre.typeSymbol.isPublic) - tree setType MethodType(Nil, erasure.getClassReturnType(pre)) + tree setType MethodType(Nil, getClassReturnType(pre)) else tree } |