Skip to content

Commit 3dc9c2e

Browse files
committed
Remove unnecessary unchecked cast
1 parent f9fc08b commit 3dc9c2e

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

java/kotlin-extractor/src/main/kotlin/KotlinFileExtractor.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4564,8 +4564,7 @@ open class KotlinFileExtractor(
45644564
extractExpressionExpr(loop.condition, callable, id, 0, id)
45654565
}
45664566

4567-
@Suppress("UNCHECKED_CAST")
4568-
private fun <T : DbExpr> exprIdOrFresh(id: Label<out DbExpr>?) = id as? Label<T> ?: tw.getFreshIdLabel()
4567+
private fun <T : DbExpr> exprIdOrFresh(id: Label<out DbExpr>?) = id?.cast<T>() ?: tw.getFreshIdLabel()
45694568

45704569
private fun toUnbound(t: IrType) =
45714570
when(t) {

0 commit comments

Comments
 (0)