Add a warning for a user-defined entries property call
^KT-53153
This commit is contained in:
committed by
Space Team
parent
695a538529
commit
989fc886e1
+21
@@ -0,0 +1,21 @@
|
||||
// !LANGUAGE: -EnumEntries
|
||||
// WITH_STDLIB
|
||||
|
||||
enum class A {
|
||||
;
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
val entries = 0
|
||||
}
|
||||
}
|
||||
|
||||
fun test() {
|
||||
A.<!DEBUG_INFO_CALL("fqName: A.Companion.entries; typeCall: variable"), DEPRECATED_ACCESS_TO_ENUM_ENTRY_COMPANION_PROPERTY!>entries<!>
|
||||
|
||||
with(A) {
|
||||
<!DEBUG_INFO_CALL("fqName: A.Companion.entries; typeCall: variable")!>entries<!>
|
||||
}
|
||||
|
||||
A.Companion.<!DEBUG_INFO_CALL("fqName: A.Companion.entries; typeCall: variable")!>entries<!>
|
||||
}
|
||||
Reference in New Issue
Block a user