diff options
Diffstat (limited to 'src/dotty/tools/dotc/transform/TypeTestsCasts.scala')
-rw-r--r-- | src/dotty/tools/dotc/transform/TypeTestsCasts.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/transform/TypeTestsCasts.scala b/src/dotty/tools/dotc/transform/TypeTestsCasts.scala index f74f4f208..8c9ffb1fb 100644 --- a/src/dotty/tools/dotc/transform/TypeTestsCasts.scala +++ b/src/dotty/tools/dotc/transform/TypeTestsCasts.scala @@ -86,7 +86,7 @@ class TypeTestsCasts extends MiniPhaseTransform { else derivedTree(box(qual), defn.Any_asInstanceOf, argType) } else if (argCls.isPrimitiveValueClass) - unbox(qual, argType) + unbox(qual.ensureConforms(defn.ObjectType), argType) else derivedTree(qual, defn.Any_asInstanceOf, argType) } |