TypeCastException when casting null to T with nullable upper-bound
#KT-3637 Fixed
This commit is contained in:
@@ -3513,7 +3513,7 @@ The "returned" value of try expression with no finally is either the last expres
|
||||
value.put(boxType(value.type), v);
|
||||
|
||||
if (opToken != JetTokens.AS_SAFE) {
|
||||
if (!rightType.isNullable()) {
|
||||
if (!CodegenUtil.isNullableType(rightType)) {
|
||||
v.dup();
|
||||
Label nonnull = new Label();
|
||||
v.ifnonnull(nonnull);
|
||||
|
||||
Reference in New Issue
Block a user