小编Uma*_*mar的帖子

如何解决kotlin协程注释警告

让我来问

我使用 kotlin 协程

@OptIn(DelicateCoroutinesApi::class)
GlobalScope.launch {
    displaySura()
}
Run Code Online (Sandbox Code Playgroud)

并在构建选项卡中显示警告:

This annotation should be used with the compiler argument '-opt-in=kotlin.RequiresOptIn'
Run Code Online (Sandbox Code Playgroud)

如何解决这个警告?提前致谢

annotations coroutine kotlin build.gradle kotlin-coroutines

9
推荐指数
2
解决办法
3303
查看次数