arrayListOf和hashMapOf:未解决的参考
问题描述:
我想在本地机器上玩Kotlin HTML builder example。arrayListOf和hashMapOf:未解决的参考
在
abstract class Tag(val name: String) : Element {
val children = arrayListOf<Element>()
val attributes = hashMapOf<String, String>()
IntelliJ IDEA的怒骂arrayListOf
和hashMapOf
是悬而未决。
导入kotlin.collections
(import kotlin.collections.*
),其中arrayListOf定义,并没有帮助。
我该如何解决这些错误?
答
请确保您使用最新的1.0 kotlin插件和1.0运行时。之后,无效IJ缓存并重新启动IJ可能是一个好主意。