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,7 +0,0 @@
object Foo {
operator fun <T> invoke() {}
}
fun main() {
Foo<Int>()
}
@@ -1,3 +1,4 @@
// FIR_IDENTICAL
object Foo {
operator fun <T> invoke() {}
}
@@ -1,23 +0,0 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
public class A {
public operator fun get(vararg attrs : Pair<String, String>) : A = this
}
operator fun String.unaryPlus() : A = A()
operator fun A.div(s : String) : A = A()
fun test() {
(+"node2" / "node3" / "zzz") ["attr" to "value", "a2" to "v2"]
}
//---------
class B {
public operator fun get(s : String, q : String) : B = this
public operator fun get(s : Pair<String, String>) : B = this
public operator fun invoke(q : B.() -> Unit) : B = this
}
val x = B()["a", "v"]["a" to "b"] {} ["q" to "p"] // does not parses around {}
//from library
data class Pair<out A, out B> (val first: A, val second: B)
infix fun <A,B> A.to(that: B) = Pair(this, that)
@@ -1,3 +1,4 @@
// FIR_IDENTICAL
// !DIAGNOSTICS: -UNUSED_PARAMETER
public class A {