Add tests for obsolete issues
#KT-32207 Obsolete #KT-32836 Obsolete #KT-32949 Obsolete #KT-9384 Obsolete
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
// !DIAGNOSTICS: -UNUSED_PARAMETER
|
||||
|
||||
inline fun <reified T> parse(json: String): T? = TODO()
|
||||
|
||||
class MyType
|
||||
|
||||
fun parseMyData(json: String): MyType =
|
||||
try {
|
||||
parse(json) // error with new inf only: Cannot use 'Nothing?' as reified type parameter
|
||||
?: throw IllegalArgumentException("Can't parse")
|
||||
} catch (e: Exception) {
|
||||
throw IllegalArgumentException("Can't parse")
|
||||
}
|
||||
|
||||
fun main() {
|
||||
parseMyData("")
|
||||
}
|
||||
Reference in New Issue
Block a user