Add KDoc to ObsoleteDescriptorBasedAPI

This commit is contained in:
Mikhail Glukhikh
2020-06-15 13:05:08 +03:00
parent a035404c96
commit aaacbaaaec
@@ -5,5 +5,13 @@
package org.jetbrains.kotlin.ir
/**
* This annotation is used on IR API elements which use front-end (FE) descriptors to obtain information, directly or indirectly.
*
* Descriptors are used in FE to represent main declaration properties and to refer declarations.
* Early IR versions were descriptor-based, so IR elements used descriptors to obtain some information about element properties.
* However, more correct and universal way is to store all necessary information inside IR elements themselves
* and do not use descriptors as some intermediate storage. It's planned to remove all descriptor usages from IR in future.
*/
@RequiresOptIn(message = "Please use IR declaration properties and not its descriptor properties", level = RequiresOptIn.Level.ERROR)
annotation class ObsoleteDescriptorBasedAPI