[FE] Provide overloadability for candidates with different CR

This commit is contained in:
Anastasiya Shadrina
2021-09-18 19:00:37 +07:00
committed by TeamCityServer
parent 155e7b211b
commit a091b345a0
12 changed files with 108 additions and 6 deletions
@@ -0,0 +1,21 @@
// !LANGUAGE: +ContextReceivers
// TARGET_BACKEND: JVM_IR
// IGNORE_BACKEND_FIR: JVM_IR
context(Int, String)
fun foo(): String = "O"
context(Int)
fun foo(): String = "K"
fun box(): String {
val o = with ("") {
with(42) {
foo()
}
}
val k = with(42) {
foo()
}
return o + k
}