Created automatic labeling of function expression.

This commit is contained in:
Stanislav Erokhin
2015-03-16 20:14:08 +03:00
parent 4eac3f3f0e
commit 446816e3db
4 changed files with 35 additions and 3 deletions
@@ -0,0 +1,15 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER -UNUSED_VARIABLE
fun <T, R> Iterable<T>.map(transform: (T) -> R): List<R> = null!!
fun autolabel(l: List<Int>) = l.map (fun (i: Int): Int {
return@map 4
})
fun unresolvedMapLabel(l: List<Int>) = l.map (fun test(i: Int): Int {
return<!UNRESOLVED_REFERENCE!>@map<!> 4
})
fun labelToFunName(l: List<Int>) = l.map (fun test(i: Int): Int {
return@test 4
})
@@ -0,0 +1,6 @@
package
internal fun autolabel(/*0*/ l: kotlin.List<kotlin.Int>): kotlin.List<kotlin.Int>
internal fun labelToFunName(/*0*/ l: kotlin.List<kotlin.Int>): kotlin.List<kotlin.Int>
internal fun unresolvedMapLabel(/*0*/ l: kotlin.List<kotlin.Int>): kotlin.List<kotlin.Int>
internal fun </*0*/ T, /*1*/ R> kotlin.Iterable<T>.map(/*0*/ transform: (T) -> R): kotlin.List<R>