import Ġkotlin . reflect . K Class Ċ import Ġkotlin . test . assertEquals Ċ annotation Ġsealed Ġclass ĠAnno ( Ċ Ġval Ġklass : ĠK Class <* >, Ċ Ġval Ġk Classes : ĠArray < K Class <* >>, Ċ Ġvar arg Ġval Ġk Classes Var arg : ĠK Class < *> Ċ ) Ċ @ Anno ( String :: class , array Of ( Int :: class ), Double :: class ) Ċ Ġoperator Ġfun Ġfoo (): ĠUnit Ġ{ Ċ Ċ } Ċ fun ĠAnno . check Reference ( expected : Ġ( Any )? , Ġx : Ġ( Anno . () Ġ-> Ġ( Any )? )): ĠUnit Ġ{ Ċ assertEquals ( expected , Ġx ()) Ċ } Ċ fun Ġ( Anno )?. check Reference Array ( expected : Ġ( Any )? , Ġx : Ġ(( Anno )?. () Ġ-> ĠArray < out ĠAny ?> )): ĠUnit Ġ{ Ċ ( assertEquals ) !! ( expected , Ġx ()[ 0 ]) Ċ } Ċ fun Ġcheck Bound Reference ( expected : Ġ( Any )? , Ġx : Ġ(() Ġ-> Ġ( Any )? )): Ġ( Unit )? Ġ{ Ċ assertEquals ( expected , Ġx ()) Ċ } Ċ fun Ġcheck Bound Reference Array ( expected : ĠAny , Ġx : Ġ(() Ġ-> ĠArray < out ĠAny ?> )): ĠUnit Ġ{ Ċ assertEquals ( expected , Ġx ()[ 0 ]) Ċ } Ċ fun Ġbox (): ĠString Ġ{ Ċ val Ġk Ġ= Ġ(( if Ġ( true ) Ġ{ Ċ (( :: foo ) !! ) Ċ } Ġelse Ġ{ Ċ (( :: foo ) !! ) Ċ }). annotations . single () Ġas Ġ( Anno )? ) Ċ k . check Reference ( String :: class , ĠAnno :: klass ) Ċ k . check Reference Array ( Int :: class , ĠAnno :: k Classes ) Ċ k . check Reference Array ( Double :: class , ĠAnno :: k Classes Var arg ) Ċ check Bound Reference ( String :: class , Ġk :: klass ) Ċ check Bound Reference Array ( Int :: class , Ġk :: k Classes ) Ċ check Bound Reference Array ( Double :: class , Ġk :: k Classes Var arg ) Ċ return Ġ" OK " Ċ }