Fix wrapWithSafeLetCall quickfix testdata

This commit is contained in:
Ilya Kirillov
2021-05-21 00:00:54 +02:00
parent be4632c2fe
commit c72b2caf3e
6 changed files with 14 additions and 0 deletions
@@ -1,4 +1,7 @@
// "Wrap with '?.let { ... }' call" "true"
// ERROR: Expression 'it' of type 'Unit' cannot be invoked as a function. The function 'invoke()' is not found
// ERROR: Function invocation 'foo2()' expected
// ERROR: Reference has a nullable type '(Str.() -> Unit)?', use explicit '?.invoke()' to make a function-like call instead
// WITH_RUNTIME
interface Str {
@@ -1,4 +1,6 @@
// "Wrap with '?.let { ... }' call" "true"
// SHOULD_BE_AVAILABLE_AFTER_EXECUTION
// ERROR: Type mismatch: inferred type is String? but String was expected
// WITH_RUNTIME
fun test(s: String?) {
@@ -1,4 +1,6 @@
// "Wrap with '?.let { ... }' call" "true"
// SHOULD_BE_AVAILABLE_AFTER_EXECUTION
// ERROR: Type mismatch: inferred type is String? but String was expected
// WITH_RUNTIME
fun test(s: String?) {
@@ -1,4 +1,6 @@
// "Wrap with '?.let { ... }' call" "true"
// SHOULD_BE_AVAILABLE_AFTER_EXECUTION
// ERROR: Type mismatch: inferred type is String? but String was expected
// WITH_RUNTIME
fun test(s: String?) {
@@ -1,4 +1,7 @@
// "Wrap with '?.let { ... }' call" "true"
// SHOULD_BE_AVAILABLE_AFTER_EXECUTION
// ERROR: A 'return' expression required in a function with a block body ('{...}')
// ERROR: Type mismatch: inferred type is String? but String was expected
// WITH_RUNTIME
fun test(s: String?): String? {
@@ -1,4 +1,6 @@
// "Wrap with '?.let { ... }' call" "true"
// SHOULD_BE_AVAILABLE_AFTER_EXECUTION
// ERROR: Type mismatch: inferred type is String? but String was expected
// WITH_RUNTIME
fun test(s: String?): String {