Enable SAM conversion for Kotlin functions by default in new inference

KT-25686
This commit is contained in:
Mikhail Zarechenskiy
2018-08-10 11:03:40 +03:00
parent 31a5746724
commit b1985ee422
11 changed files with 97 additions and 0 deletions
@@ -0,0 +1,14 @@
warning: ATTENTION!
This build uses unsafe internal compiler arguments:
-XXLanguage:+NewInference
-XXLanguage:-SamConversionForKotlinFunctions
This mode is not recommended for production use,
as no stability/compatibility guarantees are given on
compiler or generated code. Use it at your own risk!
compiler/testData/cli/jvm/newInferenceImpliesSamConversions.kt:4:9: error: type mismatch: inferred type is () -> TypeVariable(_L) but Runnable was expected
foo { }
^
COMPILATION_ERROR