UNUSED_VALUE is now reported on expression only if this expression is unused in all (e.g. finally) branches #KT-9825 Fixed
(cherry picked from commit aac8e94)
This commit is contained in:
committed by
Mikhail Glukhikh
parent
e363809b37
commit
6a9d058db4
@@ -0,0 +1,10 @@
|
||||
fun test5() {
|
||||
var a: Int
|
||||
try {
|
||||
<!UNUSED_VALUE!>a =<!> 3
|
||||
}
|
||||
finally {
|
||||
a = 5
|
||||
}
|
||||
a.hashCode()
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
package
|
||||
|
||||
public fun test5(): kotlin.Unit
|
||||
Reference in New Issue
Block a user