diff options
Diffstat (limited to 'src/compiler')
-rw-r--r-- | src/compiler/scala/tools/nsc/symtab/Definitions.scala | 2 | ||||
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/RefChecks.scala | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/symtab/Definitions.scala b/src/compiler/scala/tools/nsc/symtab/Definitions.scala index d36eb507cb..a2051c5acc 100644 --- a/src/compiler/scala/tools/nsc/symtab/Definitions.scala +++ b/src/compiler/scala/tools/nsc/symtab/Definitions.scala @@ -849,7 +849,7 @@ trait Definitions requires SymbolTable { PatternWildcard = NoSymbol.newValue(NoPos, "_").setInfo(AllClass.typeConstructor) - BoxedNumberClass = getClass("scala.runtime.BoxedNumber") + BoxedNumberClass = if (forMSIL) null else getClass("scala.runtime.BoxedNumber") BoxedArrayClass = getClass("scala.runtime.BoxedArray") BoxedAnyArrayClass = getClass("scala.runtime.BoxedAnyArray") BoxedObjectArrayClass = getClass("scala.runtime.BoxedObjectArray") diff --git a/src/compiler/scala/tools/nsc/typechecker/RefChecks.scala b/src/compiler/scala/tools/nsc/typechecker/RefChecks.scala index f4577bac74..cfb4c3e270 100644 --- a/src/compiler/scala/tools/nsc/typechecker/RefChecks.scala +++ b/src/compiler/scala/tools/nsc/typechecker/RefChecks.scala @@ -503,7 +503,7 @@ abstract class RefChecks extends InfoTransform { nonSensible("", false) else if (isNumericValueClass(receiver) && !isNumericValueClass(actual) && - !(actual isSubClass BoxedNumberClass) && + !(forMSIL || (actual isSubClass BoxedNumberClass)) && !(receiver isSubClass actual)) nonSensible("", false) else if ((receiver hasFlag FINAL) && hasObjectEquals && !isValueClass(receiver) && |