[Tests] Update test data after changes to FIR diagnostic messages

This commit is contained in:
Kirill Rakhman
2023-08-11 11:00:37 +02:00
committed by Space Team
parent de1c92a32f
commit d0cc86f52c
101 changed files with 675 additions and 227 deletions
@@ -7,7 +7,7 @@ import kotlin.contracts.*
fun foo(y: Boolean) {
val x: Int = 42
<!CONTRACT_NOT_ALLOWED("Contract should be the first statement")!>contract<!> {
<!CONTRACT_NOT_ALLOWED("Contract should be the first statement.")!>contract<!> {
returns() implies y
}
}
@@ -23,14 +23,14 @@ inline fun case1(block: () -> Unit) {
block()
}
inline fun case_2(block: () -> Unit) = <!CONTRACT_NOT_ALLOWED("Contracts are only allowed in function body blocks")!>contract<!> {
inline fun case_2(block: () -> Unit) = <!CONTRACT_NOT_ALLOWED("Contracts are only allowed in function body blocks.")!>contract<!> {
callsInPlace(<!USAGE_IS_NOT_INLINABLE!>block<!>, InvocationKind.EXACTLY_ONCE)
}
fun case_3(block: () -> Unit) {
class Class {
fun innerFun(block2: () -> Unit) {
<!CONTRACT_NOT_ALLOWED("Contracts are not allowed for local functions")!>contract<!> {
<!CONTRACT_NOT_ALLOWED("Contracts are not allowed for local functions.")!>contract<!> {
callsInPlace(block2, InvocationKind.EXACTLY_ONCE)
}
block2()
@@ -1,7 +1,7 @@
/labelClashes.fir.kt:(84,87): error: Unresolved reference: inc
/labelClashes.fir.kt:(84,87): error: Unresolved reference 'inc'.
/labelClashes.fir.kt:(151,154): error: Unresolved reference: inc
/labelClashes.fir.kt:(151,154): error: Unresolved reference 'inc'.
/labelClashes.fir.kt:(268,271): error: Unresolved reference: foo
/labelClashes.fir.kt:(268,271): error: Unresolved reference 'foo'.
/labelClashes.fir.kt:(331,334): error: Unresolved reference: foo
/labelClashes.fir.kt:(331,334): error: Unresolved reference 'foo'.
@@ -1 +1 @@
/upperBoundViolated2.fir.kt:(111,123): error: Type argument is not within its bounds: should be subtype of 'kotlin/collections/List<kotlin/CharSequence>'
/upperBoundViolated2.fir.kt:(111,123): error: Type argument is not within its bounds: should be subtype of 'kotlin/collections/List<kotlin/CharSequence>'.