mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[kotlin-dfa] Test for KTIJ-31635
GitOrigin-RevId: 18e8b35a237f588485edea8c6acf1b4945a50472
This commit is contained in:
committed by
intellij-monorepo-bot
parent
e2107bdb35
commit
2f0b30cdc4
+1
@@ -82,6 +82,7 @@ class K2DataFlowInspectionTest : AbstractK2InspectionTest() {
|
||||
fun testMath() = doTest()
|
||||
fun testMembers() = doTest()
|
||||
fun testNestedLoopLabel() = doTest()
|
||||
fun testNestedThis() = doTest()
|
||||
fun testNothingType() = doTest()
|
||||
fun testPlatformType() {
|
||||
// KTIJ-22430
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
// WITH_STDLIB
|
||||
fun Int.test() {
|
||||
val cond1 = this == 1
|
||||
if (cond1 && <warning descr="Condition 'this > 0' is always true when reached">this > 0</warning>) {}
|
||||
val cond2 = this.run { this == 1 }
|
||||
if (cond1 && <warning descr="Condition 'cond2' is always true when reached">cond2</warning>) {}
|
||||
}
|
||||
Reference in New Issue
Block a user