Add warning on -Xcoroutines flag use

The only case when warning is not reported is -Xcoroutines=default.
But this is OK until the flag is removed completely.

Original commit: cf1f194f8b
This commit is contained in:
Ilmir Usmanov
2018-07-17 23:09:56 +03:00
committed by Ilya Gorbunov
parent 9c21dae5e2
commit 1d1d959e27
@@ -54,7 +54,7 @@ object CoroutineSupport {
fun byCompilerArgumentsOrNull(arguments: CommonCompilerArguments?): LanguageFeature.State? = when (arguments?.coroutinesState) {
CommonCompilerArguments.ENABLE -> LanguageFeature.State.ENABLED
CommonCompilerArguments.WARN -> LanguageFeature.State.ENABLED_WITH_WARNING
CommonCompilerArguments.WARN, CommonCompilerArguments.DEFAULT -> LanguageFeature.State.ENABLED_WITH_WARNING
CommonCompilerArguments.ERROR -> LanguageFeature.State.ENABLED_WITH_ERROR
else -> null
}