Fix inaccurate report of DEPRECATED_ACCESS_TO_ENTRY_PROPERTY_FROM_ENUM

It can be reported not only from within the enum, but also from
top-level functions. Add separate diagnostic for such cases.

^KT-64488
This commit is contained in:
Roman Efremov
2024-02-26 16:01:53 +01:00
committed by Space Team
parent 34d87465ac
commit 02b5fed389
9 changed files with 29 additions and 3 deletions
@@ -41,7 +41,7 @@ context(Bar)
fun test3() = z
context(Bar)
fun test4() = <!DEPRECATED_ACCESS_TO_ENTRY_PROPERTY_FROM_ENUM!>entries<!>
fun test4() = <!DEPRECATED_ACCESS_TO_ENTRIES_PROPERTY!>entries<!>
context(Bar)
fun Baz.test5() = w