class Klass fun test(obj: Any): String { return when { obj is String -> "string" obj is Int -> "int" obj is Klass<*> -> "class" else -> "unknown" } }