Hello, is it possible to suppress the type parameter, when you pass it as an type argument to the function?
The first type parameter is inferred automatically, why i need to pass it with the other type parameter?
**inline fun <**R: Any**, reified E: Exception> Pair<R?, Exception?>.ex(lambda: Exception.() -> **R**): Triple<R?, Exception?, Boolean> {
val s = this.second
return if (s != null && s is E) {
Triple(s.lambda(), s, true)
}else Triple(this.first, this.second, false)
}
when apply:
.ex<**String**,IllegalArgumentException> { "" }**