indexOfFirstInstance

inline fun <T : Any> List<*>.indexOfFirstInstance(): Int

Returns the index of the first occurrence of an declaration of type T in the list, or -1 if the list does not contain any declarations of that type. non-null subtype of Any.

Return

The index of the first occurrence of an declaration of type T in the list, or -1 if not found.