UseExperimental
@Target(allowedTargets = [AnnotationTarget.CLASS, AnnotationTarget.PROPERTY, AnnotationTarget.LOCAL_VARIABLE, AnnotationTarget.VALUE_PARAMETER, AnnotationTarget.CONSTRUCTOR, AnnotationTarget.FUNCTION, AnnotationTarget.PROPERTY_GETTER, AnnotationTarget.PROPERTY_SETTER, AnnotationTarget.EXPRESSION, AnnotationTarget.FILE, AnnotationTarget.TYPEALIAS] )
Deprecated
Warning since 1.4
Error since 1.6
Please use OptIn instead.
Replace with
import kotlin.OptIn
Content copied to clipboard
OptIn(*markerClass)
Content copied to clipboard
Allows to use experimental API denoted by the given markers in the annotated file, declaration, or expression. If a declaration is annotated with UseExperimental, its usages are not required to opt-in to that experimental API.
This class is deprecated in favor of a more general approach provided by RequiresOptIn/OptIn.