Code Insight: "Generate secondary constructor" action
#KT-6970 Fixed
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateSecondaryConstructorAction
|
||||
open class Base(n: Int) {
|
||||
constructor(a: Int, b: Int): this(a + b)
|
||||
}
|
||||
|
||||
class Foo : Base {
|
||||
val x = 1
|
||||
|
||||
<caret>constructor(a: Int, b: Int) : super(a, b)
|
||||
|
||||
constructor(n: Int) : super(n)
|
||||
|
||||
fun foo() {
|
||||
|
||||
}
|
||||
|
||||
fun bar() {
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user