i was trying to constraint an Int that has a speci...
# announcements
j
i was trying to constraint an Int that has a specific annotation:
Copy code
annotation class MyAnnotation

fun <T> T.onlyOnConstrainedAnnotation() where T : @MyAnnotation Int  = {}

@MyAnnotation
val a = 0

val b = 0

a.onlyOnConstrainedAnnotation()
b.onlyOnConstrainedAnnotation()