Files
kotlin-fork/idea/testData/quickfix/changeSignature/beforeComplexHierarchy.kt
T
Pavel V. Talanov 8c95884ad2 Add new functionality to "Change signature" refactoring
Extract single point of entry for all change signature refactorings and fixes (remove parameter, add parameter)
Change signature now affects overriding functions as well
Ask the user whether he wants to refactor base function(s) or the selected one if appropiate
Fix a problem with descriptorToDeclaration in JetChangeSignatureHandler
Rename: JetFunctionPlatformDescriptor -> JetMethodDescriptor
2013-11-12 14:15:46 +04:00

59 lines
617 B
Kotlin

// "Add parameter to function 'f'" "true"
trait OA {
fun f(a: Int)
}
trait OB {
fun f(a: Int)
}
trait O : OA, OB {
override fun f(a: Int)
}
trait OO : O {
override fun f(a: Int) {
}
}
trait OOO : OO {
override fun f(a: Int) {}
}
trait OOOA : OOO {
override fun f(a: Int) {
}
}
trait OOOB : OOO {
override fun f(a: Int) {
}
}
fun usage(o: OA) {
o.f(1)
}
fun usage(o: OB) {
o.f(1)
}
fun usage(o: O) {
o.f(1)
}
fun usage(o: OO) {
o.f(13, <caret>12)
}
fun usage(o: OOO) {
o.f(3)
}
fun usage(o: OOOA) {
o.f(3)
}
fun usage(o: OOOB) {
o.f(3)
}