Load of testdata change due to contracts publishing

See changes in e2606b72bdbec2fea567d4127197707869eb801e
This commit is contained in:
Dmitry Savvinov
2018-07-27 16:43:19 +03:00
committed by Ilya Gorbunov
parent accbd07b2e
commit ee8702d21e
93 changed files with 187 additions and 95 deletions
@@ -1,7 +1,8 @@
// !LANGUAGE: +AllowContractsForCustomFunctions +UseReturnsEffect
// !USE_EXPERIMENTAL: kotlin.contracts.ExperimentalContracts
// !DIAGNOSTICS: -INVISIBLE_REFERENCE -INVISIBLE_MEMBER
import kotlin.internal.contracts.*
import kotlin.contracts.*
fun foo(b: Boolean): Boolean {
contract {
@@ -1,7 +1,8 @@
// !LANGUAGE: +AllowContractsForCustomFunctions +UseReturnsEffect
// !USE_EXPERIMENTAL: kotlin.contracts.ExperimentalContracts
// !DIAGNOSTICS: -INVISIBLE_REFERENCE -INVISIBLE_MEMBER
import kotlin.internal.contracts.*
import kotlin.contracts.*
fun bar(x: Int): Boolean = x == 0
@@ -1,7 +1,8 @@
// !LANGUAGE: +AllowContractsForCustomFunctions +UseReturnsEffect
// !USE_EXPERIMENTAL: kotlin.contracts.ExperimentalContracts
// !DIAGNOSTICS: -INVISIBLE_REFERENCE -INVISIBLE_MEMBER
import kotlin.internal.contracts.*
import kotlin.contracts.*
fun foo(boolean: Boolean) {
contract {
@@ -1,7 +1,8 @@
// !LANGUAGE: +AllowContractsForCustomFunctions +UseReturnsEffect
// !USE_EXPERIMENTAL: kotlin.contracts.ExperimentalContracts
// !DIAGNOSTICS: -INVISIBLE_REFERENCE -INVISIBLE_MEMBER
import kotlin.internal.contracts.*
import kotlin.contracts.*
fun foo(y: Boolean) {
val <!UNUSED_VARIABLE!>x<!>: Int = 42
@@ -1,7 +1,8 @@
// !LANGUAGE: +AllowContractsForCustomFunctions +UseReturnsEffect
// !USE_EXPERIMENTAL: kotlin.contracts.ExperimentalContracts
// !DIAGNOSTICS: -INVISIBLE_REFERENCE -INVISIBLE_MEMBER
import kotlin.internal.contracts.*
import kotlin.contracts.*
class Foo(val x: Int?) {
fun isXNull(): Boolean {
@@ -1,11 +1,12 @@
// !LANGUAGE: +AllowContractsForCustomFunctions +UseReturnsEffect
// !USE_EXPERIMENTAL: kotlin.contracts.ExperimentalContracts
// !DIAGNOSTICS: -INVISIBLE_REFERENCE -INVISIBLE_MEMBER
import kotlin.internal.contracts.*
import kotlin.contracts.*
fun Any?.foo(): Boolean {
contract {
returns(true) implies (<!ERROR_IN_CONTRACT_DESCRIPTION(only references to parameters are allowed. Did you miss label on <this>?)!>this<!> <!EQUALS_MISSING!>!=<!> null)
returns(true) implies (<!SENSELESS_COMPARISON!><!ERROR_IN_CONTRACT_DESCRIPTION(only references to parameters are allowed. Did you miss label on <this>?)!>this<!> != null<!>)
}
return this != null
}