Java to Kotlin converter: specify local variable type when necessary
#KT-5277 Fixed
This commit is contained in:
@@ -4,7 +4,7 @@ trait I {
|
||||
|
||||
class C() {
|
||||
fun foo(i: I, b: Boolean) {
|
||||
val result = i.getString()
|
||||
val result: String? = i.getString()
|
||||
if (b) result = null
|
||||
if (result != null) {
|
||||
print(result)
|
||||
|
||||
Reference in New Issue
Block a user