From e6912050bf6132cbe6338ce1d6786703757575ce Mon Sep 17 00:00:00 2001 From: Adriaan Moors Date: Mon, 23 Jul 2012 18:16:01 +0200 Subject: SI-2038 make pt fully-defined when typing Typed dropExistential turns existentials in the expected type (pt) that's passed to `typed` into `BoundedWildcardType`s, but those should not end up in trees when typing a `Typed` node, we didn't check for the type being fully defined (`isFullyDefined`) (and thus did not make it fully defined by turning these BWTs into existentials again using `makeFullyDefined`) --- test/files/pos/t2038.scala | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 test/files/pos/t2038.scala (limited to 'test/files/pos/t2038.scala') diff --git a/test/files/pos/t2038.scala b/test/files/pos/t2038.scala new file mode 100644 index 0000000000..17b1a702dd --- /dev/null +++ b/test/files/pos/t2038.scala @@ -0,0 +1,5 @@ +class Test { + List(Some(classOf[java.lang.Integer]), Some(classOf[Int])).map { + case Some(f: Class[_]) => f.cast(???) + } +} \ No newline at end of file -- cgit v1.2.3