Java to Kotlin converter: secondary constructors are converted to top-level functions instead of "create" functions in class object
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
fun C(p: Int): C {
|
||||
val __ = C()
|
||||
System.out.println(C.staticField1 + C.staticField2)
|
||||
return __
|
||||
}
|
||||
|
||||
class C {
|
||||
class object {
|
||||
private val staticField1 = 0
|
||||
private val staticField2 = 0
|
||||
|
||||
fun create(p: Int): C {
|
||||
val __ = C()
|
||||
System.out.println(staticField1 + C.staticField2)
|
||||
return __
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user