trait G { fun foo(t : T) : T } class GC() : G { override fun foo(t : Int) : Int { throw UnsupportedOperationException() } }