Change Signature: Constraint indices of parameters generated for overloaded versions of function with @JvmOverloads annotation

#KT-9762 Fixed
This commit is contained in:
Alexey Sedunov
2015-10-27 15:14:00 +03:00
parent 6a72b51677
commit 7ce6f58c27
4 changed files with 54 additions and 18 deletions
@@ -0,0 +1,11 @@
@JvmOverloads fun <caret>foo(aa: Int, b: Int, c: Int = 1, d: Int = 2) {
}
fun test() {
foo(aa = 1, b = 2, c = 3, d = 4)
foo(aa = 1, b = 2, c = 3)
foo(b = 1, c = 2, aa = 3)
foo(aa = 1, b = 2)
foo(b = 1, aa = 2)
}
@@ -0,0 +1,11 @@
@JvmOverloads fun <caret>foo(a: Int, b: Int, c: Int = 1, d: Int = 2) {
}
fun test() {
foo(a = 1, b = 2, c = 3, d = 4)
foo(a = 1, b = 2, c = 3)
foo(b = 1, c = 2, a = 3)
foo(a = 1, b = 2)
foo(b = 1, a = 2)
}