[FIR] Resolve type of when expression to Unit if it is not exhaustive

This commit is contained in:
Dmitriy Novozhilov
2019-10-21 11:57:16 +03:00
parent 131567474a
commit 4df4c58a05
27 changed files with 76 additions and 76 deletions
@@ -2,7 +2,7 @@ FILE fqName:<root> fileName:/tryCatchWithImplicitCast.kt
FUN name:testImplicitCast visibility:public modality:FINAL <> (a:kotlin.Any) returnType:kotlin.Unit
VALUE_PARAMETER name:a index:0 type:kotlin.Any
BLOCK_BODY
WHEN type=kotlin.Any? origin=IF
WHEN type=kotlin.Unit origin=IF
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=NOT_INSTANCEOF typeOperand=kotlin.String
GET_VAR 'a: kotlin.Any declared in <root>.testImplicitCast' type=kotlin.Any origin=null