Introduce FIR_IDENTICAL for FIR vs old frontend tests #KT-36879 Fixed

This commit is contained in:
Mikhail Glukhikh
2020-03-04 17:54:33 +03:00
parent 186e0b0cba
commit 8884cbe415
2268 changed files with 1175 additions and 19754 deletions
@@ -1,16 +0,0 @@
package test
fun a(s: String) { // <- ERROR
val (x, y) = Pair("", s)
println(x + y)
}
fun b(s: String) {
val x = Pair("", s)
println(x)
}
//from library
data class Pair<A, B>(val a: A, val b: B)
fun println(a: Any?) = a
@@ -1,3 +1,4 @@
// FIR_IDENTICAL
package test
fun a(s: String) { // <- ERROR
@@ -1,30 +0,0 @@
// !DIAGNOSTICS: -UNUSED_VARIABLE, -UNUSED_PARAMETER
fun test(list: A) {
if (true) {
val (c) = list
}
else {}
if (true) {
Unit
val (c) = list
}
else {}
when (1) {
1 -> {
val (c) = list
}
}
fn { it ->
val (a) = it
}
}
class A {
operator fun component1() = 1
}
fun fn(x: (A) -> Unit) {}
@@ -1,3 +1,4 @@
// FIR_IDENTICAL
// !DIAGNOSTICS: -UNUSED_VARIABLE, -UNUSED_PARAMETER
fun test(list: A) {