8443daf78d
They are mostly necessary for argument mapping during resolution. To support a couple checkers, we transform named args for varargs into "fake" spread expressions. Other than that, named arguments aren't needed for anything and often lead to bugs where we forget to unwrap them for something, so it's better to get rid of them. #KT-66124
67 lines
2.7 KiB
Plaintext
Vendored
67 lines
2.7 KiB
Plaintext
Vendored
FILE: callsInPlace.kt
|
|
public final fun test(): R|kotlin/Unit| {
|
|
lval x: R|kotlin/Int|
|
|
R|kotlin/run|<R|kotlin/Unit|>(<L> = run@fun <anonymous>(): R|kotlin/Unit| <inline=Inline, kind=EXACTLY_ONCE> {
|
|
R|<local>/x| = Int(1)
|
|
}
|
|
)
|
|
R|<local>/x|.R|kotlin/Int.inc|()
|
|
}
|
|
public final fun test_2(): R|kotlin/Unit| {
|
|
R|kotlin/repeat|(Int(10), <L> = repeat@fun <anonymous>(it: R|kotlin/Int|): R|kotlin/Unit| <inline=Inline, kind=UNKNOWN> {
|
|
String(test_2)
|
|
}
|
|
)
|
|
}
|
|
public final fun test_3(): R|kotlin/Unit| {
|
|
R|kotlin/repeat|(repeat@fun <anonymous>(it: R|kotlin/Int|): R|kotlin/Unit| <inline=Inline, kind=UNKNOWN> {
|
|
String(test_3)
|
|
}
|
|
, Int(10))
|
|
}
|
|
public final fun test_4(): R|kotlin/Unit| {
|
|
Int(1).R|kotlin/takeUnless|<R|kotlin/Int|>(<L> = takeUnless@fun <anonymous>(it: R|kotlin/Int|): R|kotlin/Boolean| <inline=Inline, kind=EXACTLY_ONCE> {
|
|
String(test_4)
|
|
^ CMP(>, R|<local>/it|.R|kotlin/Int.compareTo|(Int(0)))
|
|
}
|
|
)
|
|
}
|
|
public final fun test_5(): R|kotlin/Unit| {
|
|
Int(1).R|kotlin/takeUnless|<R|kotlin/Int|>(takeUnless@fun <anonymous>(it: R|kotlin/Int|): R|kotlin/Boolean| <inline=Inline, kind=EXACTLY_ONCE> {
|
|
String(test_5)
|
|
^ CMP(>, R|<local>/it|.R|kotlin/Int.compareTo|(Int(0)))
|
|
}
|
|
)
|
|
}
|
|
public final inline fun myRun(block1: R|() -> kotlin/Unit|, block2: R|() -> kotlin/Unit|): R|kotlin/Unit| {
|
|
R|<local>/block1|.R|SubstitutionOverride<kotlin/Function0.invoke: R|kotlin/Unit|>|()
|
|
R|<local>/block2|.R|SubstitutionOverride<kotlin/Function0.invoke: R|kotlin/Unit|>|()
|
|
}
|
|
public final fun test_6(): R|kotlin/Unit| {
|
|
R|/myRun|(myRun@fun <anonymous>(): R|kotlin/Unit| <inline=Inline, kind=UNKNOWN> {
|
|
String(test_6_1)
|
|
}
|
|
, <L> = myRun@fun <anonymous>(): R|kotlin/Unit| <inline=Inline, kind=UNKNOWN> {
|
|
String(test_6_2)
|
|
}
|
|
)
|
|
}
|
|
public final fun test_7(): R|kotlin/Unit| {
|
|
R|/myRun|(myRun@fun <anonymous>(): R|kotlin/Unit| <inline=Inline, kind=UNKNOWN> {
|
|
String(test_7_2)
|
|
}
|
|
, myRun@fun <anonymous>(): R|kotlin/Unit| <inline=Inline, kind=UNKNOWN> {
|
|
String(test_7_1)
|
|
}
|
|
)
|
|
}
|
|
public final fun myDummyRun(block: R|() -> kotlin/Unit|): R|kotlin/Unit| {
|
|
R|<local>/block|.R|SubstitutionOverride<kotlin/Function0.invoke: R|kotlin/Unit|>|()
|
|
}
|
|
public final fun test_8(): R|kotlin/Unit| {
|
|
R|/myDummyRun|(<L> = myDummyRun@fun <anonymous>(): R|kotlin/Unit| <inline=NoInline> {
|
|
String(test_8)
|
|
}
|
|
)
|
|
}
|