KT-6244 Overloads with no default parameters should take over ones with defaults

#KT-6244 Fixed
This commit is contained in:
Stanislav Erokhin
2015-08-31 22:07:37 +03:00
parent 5ded315cbb
commit d015f713cb
14 changed files with 99 additions and 16 deletions
@@ -6,5 +6,5 @@ fun foo(s: String) {}
fun bar(f: () -> Unit) = 1
fun bar(f: (String) -> Unit) = 2
val x1 = ::<!OVERLOAD_RESOLUTION_AMBIGUITY!>foo<!> as () -> Unit
val x2 = bar(::<!OVERLOAD_RESOLUTION_AMBIGUITY!>foo<!> as (String) -> Unit)
val x1 = ::foo <!USELESS_CAST!>as () -> Unit<!>
val x2 = bar(<!UNCHECKED_CAST!>::foo as (String) -> Unit<!>)