FIR checker: support DUPLICATE_LABEL_IN_WHEN

Changes from FE1.0:
1. As discussed previously, no expression evaluation happens during this
check.
2. FE1.0 doesn't check redundant object comparisons.
This commit is contained in:
Tianyu Geng
2021-06-23 13:31:40 -07:00
committed by Mikhail Glukhikh
parent 7c6326856b
commit 4915d8dda3
12 changed files with 109 additions and 17 deletions
@@ -6,6 +6,7 @@ package test {
public fun first(/*0*/ arg: kotlin.Int): kotlin.Int
public fun fourth(/*0*/ arg: test.Color): kotlin.String
public fun second(/*0*/ arg: kotlin.String): kotlin.Int
public fun sixth(/*0*/ arg: kotlin.Any?): kotlin.String?
public fun third(/*0*/ arg: kotlin.Any?): kotlin.Int
public final enum class Color : kotlin.Enum<test.Color> {
@@ -30,4 +31,12 @@ package test {
public final /*synthesized*/ fun valueOf(/*0*/ value: kotlin.String): test.Color
public final /*synthesized*/ fun values(): kotlin.Array<test.Color>
}
public object Foo {
private constructor Foo()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
}